0
votes

I have a working app service named "matanwebserver" over a subscription in Azure. This is a website that I am working on. I work with Visual Studio and I wrote my code inside this app service in Visual Studio.

Now I want to create an Integration site so I can test my code before publishing to the production site. For that, I created a new app service in azure under the name "matanwebservertest" and I want to use the code I wrote for "matanwebserver" over the new app service that I just created.

I could not find any source which provides a solution, so thanks in advance.

Added some screenshots for a better understanding of the issue

  1. In Visual Studio I do right click on the web app which is called "MatanWebServer" and choose "publish". Then I choose the new web app that I just created on Azure portal which called "matanwebserertest", and publish successfully. enter image description here

  2. This is the original (production) website. which its address is http://matanwebserver.azurewebsites.net

enter image description here

  1. After publish to the matanwebservertest web app, I expect to see a "copy" of the original site, but it seems like nothing is there. enter image description here
1
try publishing it from VS to new app in AzureZahid Faroq

1 Answers

0
votes

To get the current app cloned to the new one, have a look at the 'Clone App' option.

enter image description here

What you're trying to do feels like a perfect example to use for using Deployment Slots Please refer to Set up staging environments in Azure App Service.

When you deploy your web app, web app on Linux, mobile back end, and API app to App Service, you can deploy to a separate deployment slot instead of the default production slot when running in the Standard or Premium App Service plan tier. Deployment slots are actually live apps with their own hostnames. App content and configurations elements can be swapped between two deployment slots, including the production slot. Deploying your application to a deployment slot has the following benefits:

  • You can validate app changes in a staging deployment slot before swapping it with the production slot.
  • Deploying an app to a slot first and swapping it into production ensures that all instances of the slot are warmed up before being swapped into production. This eliminates downtime when you deploy your app. The traffic redirection is seamless, and no requests are dropped as a result of swap operations. This entire workflow can be automated by configuring Auto Swap when pre-swap validation is not needed.
  • After a swap, the slot with previously staged app now has the previous production app. If the changes swapped into the production slot are not as you expected, you can perform the same swap immediately to get your "last known good site" back.