{"id":228128,"date":"2021-05-13T09:55:15","date_gmt":"2021-05-13T16:55:15","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/java\/?p=228128"},"modified":"2021-05-13T10:02:12","modified_gmt":"2021-05-13T17:02:12","slug":"automate-spring-boot-application-deployments-to-azure","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/java\/automate-spring-boot-application-deployments-to-azure\/","title":{"rendered":"Automate Spring Boot application deployments to Azure!"},"content":{"rendered":"<p>Today, we\u2019re excited to announce the availability of the Azure Pipeline Task for deploying Spring Boot applications to Azure Spring Cloud. You can get started by building your pipelines using the <a href=\"https:\/\/aka.ms\/automate-application-deployments-to-azure-spring-cloud\">Azure Spring Cloud task<\/a> to automate Spring Boot application deployments to any number of environments and Azure Regions.<\/p>\n<p>Over the past 18 months, we worked with many enterprise customers to learn about their scenarios including thoughts on automating end-to-end from idea to provisioning Azure resources to building Spring Boot applications to deploying those applications to production. Many of these customers have thousands of Spring Boot applications running in on-premises data centers. As they migrate these applications to the cloud, they need everything automated end-to-end to ensure repeatability and meet the requirements set forth by their IT departments and\/or regulatory bodies. They require a fully-featured Continuous Integration \/ Continuous Delivery (CI\/CD) service that can automatically deploy updated Spring Boot applications to Azure Spring Cloud. In many customer environments, they use Azure CLI in Azure Pipelines to automate Spring Boot application deployments to Azure, and they asked Microsoft for an Azure Spring Cloud task to ease their automation effort and delegate the maintenance of the deployment task to Microsoft. Now, using the new Azure Spring Cloud task, anyone can automate deployments straight to production or automate blue-green strategies to stage for testing and then set to production.<\/p>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em><em style=\"font-size: 1rem;\">\u201c<\/em>We are pleased to see further incremental improvements and simplifications and we plan to migrate our pipelines to use the out of the box tasks soon.\u201d \u2013 Jonathan Jones, Lead Solutions Architect, <\/em><a href=\"https:\/\/www.swissre.com\/\"><em>Swiss Re Management Ltd.<\/em><\/a><em> (Switzerland)<\/em><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em style=\"font-size: 1rem;\">\u201cAzure Spring Cloud makes Spring Boot applications easy to deploy on Azure and provides wonderful features like App Insights, network isolation using Azure virtual network, blue-green deployments that help us deploy &amp; monitor our applications easily. With every release of Azure Spring Cloud, we are able to find greater ease of integration and deployment of our applications.\u201d &#8211; Shyam Kumar Sundarakumar, Senior Solutions Architect, <\/em><a style=\"background-color: #f7f7f9; font-size: 1rem;\" href=\"https:\/\/www.hcltech.com\/\"><em>HCL Technologies Ltd<\/em><\/a><em style=\"font-size: 1rem;\"> (India).<\/em><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em>\u201cThe Azure Pipelines Tasks for Azure Spring Cloud greatly simplifies creating automated CI\/CD pipelines to deploy spring boot apps. These new tasks have the net effect of reducing cost, effort and time as well as adding robustness to deploying Spring Boot applications. These services will help Insight to guide their clients in automating their workloads end to end in Azure Spring Cloud.\u201d \u2013 Dan Lange, Principal Architect, <\/em><a href=\"https:\/\/www.insight.com\/\"><em>Insight<\/em><\/a><em> (United States)<\/em><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em>\u201cWith the introduction of Azure Spring Cloud Task for Azure Pipelines, Microsoft has eliminated the pain of developing and maintaining scripts for Blue-Green Deployments for Spring Boot apps in Azure. These new features will allow Kin + Carta to help customers automate the CI\/CD pipeline including the creation, assignment and maintenance of Production and Staging Deployments.\u201d \u2013 Sudeep Moothedath, Enterprise Architect, <\/em><a href=\"https:\/\/www.kinandcarta.com\/en-us\/\"><em>Kin + Carta<\/em><\/a><em> (United States)<\/em><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em>\u201cMicrosoft continues to enhance the support for Spring Cloud! With the addition of the Azure DevOps pipeline task for Azure Spring Cloud Microsoft removes another obstacle in creating a highly flexible CI\/CD pipeline for Spring Cloud. The Azure DevOps pipeline tasks allow developers to deploy to Spring Cloud applications to any number of environments while focusing on their application logic and letting Microsoft focus on the infrastructure and maintenance of pipeline tasks.\u201c \u2013 Armando Guzman, Principal Software Engineer, Unified Commerce, <\/em><a href=\"https:\/\/www.raleys.com\/about\/raleys-corporate-fact-sheet\/\"><em>Raley\u2019s<\/em><\/a><em> (United States)<\/em><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"padding-left: 40px;\"><em>\u201cWe are really happy about the Azure Pipelines Task for Azure Spring Cloud. It is well integrated and makes deployments to Azure Spring Cloud easily by offering the relevant parameters for selection. They are helpful for managing our various app deployments and switch them in multiple environments without writing any CLI statements.\u201d \u2013 <\/em><a href=\"https:\/\/www.linkedin.com\/in\/georg-deschler-2395a52\/\"><em>Georg Deschler<\/em><\/a><em> and Philipp Stussak (Germany)<\/em><\/p>\n<\/blockquote>\n<h2>Automate blue-green application deployment strategies<\/h2>\n<p>Azure Spring Cloud Standard permits two deployments for every application. Of those two deployments, one receives <em>Production<\/em> traffic. The second deployment is designated for <em>Staging<\/em>. You can implement a simple blue-green strategy with Azure Spring Cloud by creating two fixed deployments for every application and automating deployments to the <em>Staging<\/em> deployment. When you are confident with a deployment in <em>Staging<\/em>, you can set the deployment as <em>Production<\/em>. You can use the new Azure Spring Cloud task in Azure Pipelines to implement this strategy.<\/p>\n<p>Stage 1 \u2013 automate deployments to the <em>Staging<\/em> deployment.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-228132\" src=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021.jpg\" alt=\"Image azure services for deploying java applications 05 12 2021\" width=\"1911\" height=\"1125\" srcset=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021.jpg 1911w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021-300x177.jpg 300w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021-1024x603.jpg 1024w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021-768x452.jpg 768w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-05-12-2021-1536x904.jpg 1536w\" sizes=\"(max-width: 1911px) 100vw, 1911px\" \/><\/a><\/p>\n<p>When you run the pipeline, you can watch the progress through Azure Pipelines Logs as illustrated below.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs.png\"><img decoding=\"async\" class=\"alignnone size-full wp-image-228133\" src=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs.png\" alt=\"Image azure pipelines logs\" width=\"1878\" height=\"1531\" srcset=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs.png 1878w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs-300x245.png 300w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs-1024x835.png 1024w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs-768x626.png 768w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-pipelines-logs-1536x1252.png 1536w\" sizes=\"(max-width: 1878px) 100vw, 1878px\" \/><\/a><\/p>\n<p>Stage 2: Set the previous deployment to <em>Production<\/em>.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-228131\" src=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021.jpg\" alt=\"Image azure services for deploying java applications 2 05 12 2021\" width=\"1911\" height=\"1125\" srcset=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021.jpg 1911w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021-300x177.jpg 300w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021-1024x603.jpg 1024w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021-768x452.jpg 768w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/azure-services-for-deploying-java-applications-2-05-12-2021-1536x904.jpg 1536w\" sizes=\"(max-width: 1911px) 100vw, 1911px\" \/><\/a><\/p>\n<p>For development and test environments, where disruption is not on the critical path, you can either implement blue-green deployment strategies or you can directly deploy applications to deployments that are receiving <em>Production<\/em> traffic. The new Azure Spring Cloud task also supports deploying applications to deployments that are receiving <em>Production<\/em> traffic.<\/p>\n<h2>Automate end-to-end \u2013 from idea to production<\/h2>\n<p>When you deploy Spring Boot applications to Azure Spring Cloud and Azure, you can build end-to-end automation from idea to provisioning Azure resources to building Spring Boot applications to deploying those applications to production using any automation tools and platforms of your choice \u2013 such as Azure DevOps, Jenkins, Maven or Gradle. You can apply this automation strategy to any environment, including development, test and production, and any region.<\/p>\n<p>Typically, developers automate end-to-end by using multiple pipelines which are broadly classified into three categories:<\/p>\n<ul>\n<li><strong>Provision<\/strong> \u2013 automate provisioning Azure resources using <a href=\"https:\/\/github.com\/Azure\/azure-spring-cloud-reference-architecture\/tree\/main\/terraform\/brownfield-deployment\">Terraform<\/a>, <a href=\"https:\/\/github.com\/Azure\/azure-spring-cloud-reference-architecture\/tree\/main\/ARM\/brownfield-deployment\">ARM template<\/a> and or <a href=\"https:\/\/github.com\/Azure\/azure-spring-cloud-reference-architecture\/tree\/main\/CLI\/brownfield-deployment\">Azure CLI<\/a><\/li>\n<li><strong>Build<\/strong> \u2013 automate building and storing binary artifacts such as JARs and WARs using Maven or Gradle<\/li>\n<li><strong>Deploy<\/strong> \u2013 automate deployments using Azure Pipelines, GitHub Actions and Azure CLI. Blue-green deployment strategies without any disruption to production traffic are very popular. Developers who use Azure Pipelines can leverage the new Azure Spring Cloud task to automate blue-green deployment strategies<\/li>\n<\/ul>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2.jpg\"><img decoding=\"async\" class=\"alignnone size-full wp-image-228130\" src=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2.jpg\" alt=\"Image automate from idea to production 2\" width=\"1937\" height=\"1086\" srcset=\"https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2.jpg 1937w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2-300x168.jpg 300w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2-1024x574.jpg 1024w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2-768x431.jpg 768w, https:\/\/devblogs.microsoft.com\/java\/wp-content\/uploads\/sites\/51\/2021\/05\/automate-from-idea-to-production-2-1536x861.jpg 1536w\" sizes=\"(max-width: 1937px) 100vw, 1937px\" \/><\/a><\/p>\n<h2>Learn more about Azure Spring Cloud and start building and automating today!<\/h2>\n<p>Azure Spring Cloud is jointly built, operated, and supported by Microsoft and VMware. It is a fully managed service for Spring Boot applications. Azure Spring Cloud abstracts away the complexity of infrastructure management and Spring Cloud middleware management, so you can focus on building your business logic and let Azure take care of dynamic scaling, patches, security, compliance, and high availability. With a few steps, you can provision Azure Spring Cloud, create applications, deploy, and scale Spring Boot applications, automate end-to-end and start monitoring in minutes. We\u2019ll continue to bring more developer-friendly and enterprise-ready features to Azure Spring Cloud.<\/p>\n<p>Get started with the <a href=\"https:\/\/aka.ms\/automate-application-deployments-to-azure-spring-cloud\">Azure Spring Cloud task for Azure Pipelines<\/a> to automate Spring Boot application deployments and these resources below!<\/p>\n<h2>Resources<\/h2>\n<ul>\n<li>Learn using an <a href=\"https:\/\/docs.microsoft.com\/en-us\/learn\/modules\/azure-spring-cloud-workshop\/\">Microsoft Learn module<\/a> or <a href=\"https:\/\/github.com\/microsoft\/azure-spring-cloud-training\">self-paced workshop<\/a> on GitHub<\/li>\n<li>Learn <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/spring-cloud\/\">more<\/a> about implementing solutions on Azure Spring Cloud<\/li>\n<li><a href=\"https:\/\/github.com\/Azure-Samples\/spring-petclinic-microservices\">Deploy<\/a> a distributed version of Spring Petclinic built with Spring Cloud<\/li>\n<li>Learn about how to <a href=\"https:\/\/aka.ms\/automate-application-deployments-to-azure-spring-cloud\">Automate Application Deployments to Azure Spring Cloud<\/a><\/li>\n<li>Learn about <a href=\"https:\/\/aka.ms\/blue-green-deployment-strategies-in-azure-spring-cloud\">Blue-Green Deployment Strategies in Azure Spring Cloud<\/a><\/li>\n<li>Reference document \u2013 <a href=\"https:\/\/aka.ms\/azure-spring-cloud-task\">Azure Spring Cloud task for Azure Pipelines<\/a><\/li>\n<li>Deploy Spring Boot applications by leveraging enterprise best practices \u2013 <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/spring-cloud\/reference-architecture\">Azure Spring Cloud Reference Architecture<\/a><\/li>\n<li>Migrate your <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/developer\/java\/migration\/migrate-spring-boot-to-azure-spring-cloud\">Spring Boot<\/a>, <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/developer\/java\/migration\/migrate-spring-cloud-to-azure-spring-cloud\">Spring Cloud<\/a>, and <a href=\"https:\/\/aka.ms\/migrate-tomcat-to-azure-spring-cloud-service\">Tomcat<\/a> applications to Azure Spring Cloud<\/li>\n<li>Wire Spring applications to <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/developer\/java\/spring-framework\/\">interact with Azure services<\/a><\/li>\n<li>For feedback and questions, please <a href=\"mailto:AzureSpringCloud-Talk@service.microsoft.com\">e-mail<\/a><\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Today, we\u2019re excited to announce the availability of the Azure Pipeline Task for deploying Spring Boot applications to Azure Spring Cloud. You can get started by building your pipelines using the Azure Spring Cloud task to automate Spring Boot application deployments to any number of environments and Azure Regions. Over the past 18 months, we [&hellip;]<\/p>\n","protected":false},"author":12323,"featured_media":228148,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[14,1,8,17],"tags":[763,764,781,771,759,772,29,248,773,19,761,538,762],"class_list":["post-228128","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cloud","category-java","category-open-source","category-web","tag-arm-template","tag-azure-cli","tag-azure-devops","tag-azure-pipelines","tag-azure-spring-cloud","tag-github-actions","tag-gradle","tag-java","tag-jenkins","tag-maven","tag-spring-boot","tag-spring-cloud","tag-terraform"],"acf":[],"blog_post_summary":"<p>Today, we\u2019re excited to announce the availability of the Azure Pipeline Task for deploying Spring Boot applications to Azure Spring Cloud. You can get started by building your pipelines using the Azure Spring Cloud task to automate Spring Boot application deployments to any number of environments and Azure Regions. Over the past 18 months, we [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/posts\/228128","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/users\/12323"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/comments?post=228128"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/posts\/228128\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/media\/228148"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/media?parent=228128"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/categories?post=228128"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/java\/wp-json\/wp\/v2\/tags?post=228128"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}