I am using a class library to consume a service in AX. Works fine on Dev and Staging as the hosting server is reachable by Dev and Staging environments.

Now, how can I replace the service in "service references" with the one hosted on production web server, before moving the model store to production? If I try to simply update the service reference, its not saving the project successfully since it is not able to access the production server.

If I update the service after moving it to production, the change is reflected in usr layer. Do we have a way to deploy the services to var layer without providing the production web server access to staging environment ?

Thanks in advance.