We have a web project set up to deploy the same project to a handful of azure websites. When deploying to these websites, deployment in Debug mode works as expected. However when trying to deploy the same project to a website in Release mode, we are always prompted for a password.
Have tried deleting the .pubxml and .pubxml.user files, but the issue persists. Why would it deploy OK in Debug mode, but prompt for a password in Release mode?
Note: most of these projects deploy to virtual directories marked as applications in these websites. Other projects deploy just fine in release and debug mode, it seems to be just one project we are having issues with.
In Solution Explorer, select the project. Select the Properties icon (or press Alt+Enter ). In the Configuration list, choose Debug or Release. In the side pane, choose Linker > Debugging, then select options for Generate Debug Info.
Set debug and release configurations in Visual Studio. Visual Studio projects have separate release and debug configurations for your program. You build the debug version for debugging and the release version for the final release distribution. In debug configuration, your program compiles with full symbolic debug information and no optimization.
The release configuration of your program has no symbolic debug information and is fully optimized. For managed code and C++ code, debug information can be generated in.pdb files, depending on the compiler options that are used. Creating.pdb files can be useful if you later have to debug your release version.
Release Mode. Developer use release mode for final deployment of source code on live server. Release mode dlls contain optimized code and it is for customers. Release mode has below features: More optimized code. Some additional instructions are removed and developer can’t set a breakpoint on every source code line.
Still not sure why this was only happening with one of the virtual directory applications on the site, but going to the azure portal and clicking "Reset your publish profile credentials" seems to have fixed it.
This happend on VS 2017 when I tryied to update a setting in the profile. The next time I tried to publish, the password was wacked and it started prompting me.
I realized that deleting the profile from within the Publish UI in VS did not work either because all it does is remove the .Pubxml from the project without deleting it from the HD and Source control. Furthermore, if you don't delete the file manually, importing the setting whill leave you hanging; literally.
Again, the solution is to delete the file manually (both from the HD and from source control). Then importing it worked like a charm.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With