Clone your web app content between two azure web apps or slots

Once you have a stage web app (or deployment slot ) , you need an easy way to port content from your primary web app to stage web app or slot . Here is a tool that allows you do exactly this ..

Usage

Download the tool from Release folder. Before running the tool download the source and destination web app’s publish settings file from the Azure Portal . If your application has a database , update SQLServerDBConnectionString (if using sql azure databse) or mySQLDBConnectionString ( if using mysql datbase) to point to remote database associated with the app

   AzureWebAppClone.exe -s path-to-source-publish-settings -d path-to-dest-publish-settings

Example

AzureWebAppClone.exe -s "c:\publish\site1.publishsettings" -d "c:\publish\site2.publishsettings"

Sample Publish settings file

You can download the publish settings files from the Azure portal and use this template to create your own

<publishData>
 <!-- Web deploy publish method is used by this tool -->
   <publishProfile profileName="phpsimplesite-stage - Web Deploy" 
     publishMethod="MSDeploy" publishUrl="mysitename.scm.azurewebsites.net:443" 
     msdeploySite="mysitename" userName="$mysitename"         
     userPWD="lk49jRLwy9Crf0Ecy6ZunzflTcvjjiY6rQtNEaLn5Wwdsn5p3lnJZoqJJ7mp" 
     destinationAppUrl="http://mysitename.azurewebsites.net" SQLServerDBConnectionString="" 
     mySQLDBConnectionString="Database=wordpress2stage;Data Source=us-cdbr-azure-west-c.cloudapp.net;User 
     Id=b1e3c09216e681;Password=22pl09f4" 
     hostingProviderForumLink=""
     controlPanelLink="http://windows.azure.com" 
     webSystem="WebSites">
     <databases>
         <add name="default" connectionString="Database=wordpress2stage;Data Source=us-cdbr-azure-west-c.cloudapp.net;User Id=b1e3c01216e681;Password=22a809f4" providerName="MySql.Data.MySqlClient" type="MySql"/>
     </databases>
   </publishProfile>  
  </publishData>
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s