Get your own Azure button — NOW!

Easy deployment with literally one press of a button. This is every techies dream. You (nearly) can do this by providing a deployment button for your Azure services to e.g. your GitHub repositories.

In most cases you have the ARM template for your service already in place for being able to automate your deployment e.g. via the Azure CLI. Now it’s an easy one to use your ARM template for making the usage of your service a lot easier for other techies.

Wanna know how to integrate and configure the button? Let’s go!

The button itself

… is just an image. Set the image from http://azuredeploy.net/deploybutton.png to the link pointing to the repo you would like to deploy and add it to your ReadMe.md to “configure” it.

<a href="https://azuredeploy.net/
repository=https://github.com/codePrincess/resizingService"
target="_blank">
<img src="http://azuredeploy.net/deploybutton.png"/>
</a>

Prerequisites for making the button work

You need to have an ARM template in place which allows you to automatically deploy services to Azure. Additionally you have to follow the naming convention for those files:

  • azuredeploy.json
    The file which knows the whole service configuration. This is the ARM template itself.
  • parameters.json
    All available parameters defined in this file are shown to the user for configuration during the visualised deployment process, which is triggered right after pressing the button. 
    So chose wisely what you want the user to set independently. To be on the save side, work with “defaultValue” in the azuredeploy.json and just let the user configure what he really needs to.
TAKE CARE: Location of the files!
The files need to be located in the root directory of your repository. Otherwise they won’t be found by the deployment process and therefore can’t be used… Captain Obvious!
ATTENTION: Tha naming!
If you don’t follow the JSON files naming convention, the deployment won’t work. 
The deployment process parses the parameter.json first for getting all valid inputs, which are then used to fill the azuredeploy.json actual deployment.

DONE!

You now have a new and shiny Azure deployment button in place to help others use your Azure services faster without a lot of frustration or failing configurations during deployments. Make other techies happier! :D

Hint and help needed?

If you got stuck or are unsure to do this by yourself, have a look at this repository where everything is neatly in place for a one-button-click-deployment.
https://github.com/codePrincess/resizingService

This blog post gives a nice overview of how ARM templates basically work
https://elliotthamai.wordpress.com/2014/11/15/using-custom-arm-templates-with-the-deploy-to-azure-button/

But don’t be afraid, you don’t have to go alone :) There is a big bunch of templates ready to use for you for nearly every single service which is available for you on Azure
https://github.com/Azure/azure-quickstart-templates

And last but not least, let’s give a short applause to the official documentation — in case you want the really deep down insights
https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-overview

Happy coding … and deploying!

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.