This repo acts as a sample of Jakarta EE code that shows how to deploy to Microsoft Azure through Docker and Azure Web Apps for Containers.
#Steps
- Create an Azure account if you don't have one, and create an Azure Container Registry (Similar to Docker registry)
- Enable Admin on the ACR and note the URL and password generated
- Add the URL as id and password to your Maven settings.xml in ~/.m2/settings.xml similar to
<servers>
<server>
<id>[Azure ACR URL]</id>
<username>[Generated Username]</username>
<password>[Generated Password]</password>
</server>
</servers>
- Make similar changes in project pom.xml file
- Create an Azure Web App for Containers and choose your container registry
- To push code to ACR, simply run
mvn clean package
mvn deploy
Visit https://jakarta-ee.azurewebsites.net/hello-jakarta to see this sample in action!