I am developing a provider hosted app for SharePoint 2013. When developing the app I would like to use IIS for the remote web (an MVC app) and store the URL in the User Options file (.csproj.user) rather than the project file as it needs to be different for each developer. I can do this by deselecting the 'apply server settings to all users (store in project file)' option in the project > web properties dialog in Visual Studio 2012. When I deploy the app with this configuration, however, I receive the following error:
Microsoft.SharePoint.SPException: Invalid URL: ~remoteAppUrl/?SPHostUrl=...
This works correctly when the IIS Url is stored in the project file (.csproj) but I would like to avoid storing this in the project file and therefore source control as the setting is different per developer. Storing this value in the project file results in the project breaking each time a different developer checks in and another developer gets the latest version from source control.
Is there any way to enable this scenario so the ~remoteAppUrl token is resolved correctly when the URL is different for each developer? The developers need to test the application from a browser on a separate computer that is in a restricted environment so we cannot use localhost or create host entries for the remote web URL.