Nil Pun
Nil Pun

Reputation: 17373

Powershell - Create Azure Deployment Package

I've a web solution with 4 web projects. On successful build I need to create a azure deployment package via powershell.

Could someone help me whether we can create a azure deployment packages (cspkg, csdef and cscfg).

Thanks.

Upvotes: 3

Views: 5792

Answers (3)

AbhishekAnand
AbhishekAnand

Reputation: 132

Here is a good example: Windows Azure 4: Deploying via PowerShell

Also: Publish a Package using a Powershell Script

This describe the process in detail.

Upvotes: 3

Kenneth
Kenneth

Reputation: 28737

I wrote an article about build package files and uploading them to Azure using Powershell which might be useful:

http://www.kenneth-truyers.net/2014/02/06/deploying-cloud-services-to-azure-with-powershell/

Creating a package is rather simple. You can use Msbuild for that:

exec { msbuild <path-to-csproj> /p:Configuration=Release 
                                /p:DebugType=None
                                /p:Platform=AnyCpu
                                /p:OutputPath=<path-to-package>
                                /p:TargetProfile=Cloud
                                /t:publish
                                /verbosity:quiet }

Upvotes: 1

Gaurav Mantri
Gaurav Mantri

Reputation: 136126

For this, your solution must contain cloud projects so that your projects are enabled to be deployed in Windows Azure. See this guide for a step-by-step approach to do so: http://msdn.microsoft.com/en-us/library/windowsazure/hh420322.aspx. Then, when you build your cloud projects (either through msbuild or directly through Visual Studio), you'll get package files.

Upvotes: 1

Related Questions