Skip to content

Commit f9c0bdc

Browse files
committed
aks to aca
1 parent 7163018 commit f9c0bdc

File tree

11 files changed

+41
-41
lines changed

11 files changed

+41
-41
lines changed

LabTips.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ To rebuild and redeploy a failing microservice:
4949
1. Navigate to the root of the application and rebuild the specific microservice.
5050

5151
```bash
52-
cd ~/workspaces/java-microservices-aks-lab/src
52+
cd ~/workspaces/java-microservices-aca-lab/src
5353
mvn clean package -DskipTests -rf :spring-petclinic-<microservice-name>
5454
```
5555

@@ -124,7 +124,7 @@ In case you made an error in the config repo. Fixing that error in the config re
124124
1. re-apply the yaml file.
125125

126126
```bash
127-
cd ~/workspaces/java-microservices-aks-lab/src/kubernetes
127+
cd ~/workspaces/java-microservices-aca-lab/src/kubernetes
128128
kubectl apply -f spring-petclinic-<service-name>.yml
129129
```
130130

@@ -166,8 +166,8 @@ So no worries, make your config repo public and proceed! You may need to also re
166166

167167
In case you are using a codespace for running this lab, your environment variables will be lost if the codespace restarts. For persisting these environment variables, you can either use the [guidance that GitHub provides for this](https://docs.github.com/en/enterprise-cloud@latest/codespaces/developing-in-codespaces/persisting-environment-variables-and-temporary-files). We recommend the [single workspace](https://docs.github.com/en/enterprise-cloud@latest/codespaces/developing-in-codespaces/persisting-environment-variables-and-temporary-files#for-a-single-codespace) approach, since that is the easiest to set up and doesn't require workspace restart.
168168

169-
You can find a [samplebashrc file](https://github.com/Azure-Samples/java-microservices-aks-lab/blob/main/solution/samplebashrc) in this repository. You will need to update a couple of values in this file for your specific situation.
169+
You can find a [samplebashrc file](https://github.com/Azure-Samples/java-microservices-aca-lab/blob/main/solution/samplebashrc) in this repository. You will need to update a couple of values in this file for your specific situation.
170170

171171
Another approach would be to create a dedicated _.azcli_ file where you keep all environment variables. After a workspace restart, you first rerun all the steps in this file and you are good to go again.
172172

173-
You can find a [sampleENVIRONMENT.azcli file](https://github.com/Azure-Samples/java-microservices-aks-lab/blob/main/solution/sampleENVIRONMENT.azcli) in this repository. You will need to update a couple of values in this file for your specific situation.
173+
You can find a [sampleENVIRONMENT.azcli file](https://github.com/Azure-Samples/java-microservices-aca-lab/blob/main/solution/sampleENVIRONMENT.azcli) in this repository. You will need to update a couple of values in this file for your specific situation.

_config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ title: Java microservices on ACA
22
description: This lab walks you through the creation of a Java microservices application on Azure Container Apps integrated with multiple Azure services
33
theme: just-the-docs
44

5-
# url: https://Azure-Samples.github.io/java-microservices-aks-lab
5+
# url: https://Azure-Samples.github.io/java-microservices-aca-lab
66

77
aux_links:
88
"Java microservices on ACA lab on GitHub":

config/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44

55
Configuration repository for distributed Spring Petclinic application
66

7-
This folder for the config repository is a close copy of the [spring-petclinic-microservices-config](https://github.com/spring-petclinic/spring-petclinic-microservices-config) repository and is used in the [Java microservices on AKS](https://azure-samples.github.io/java-microservices-aks-lab/) lab.
7+
This folder for the config repository is a close copy of the [spring-petclinic-microservices-config](https://github.com/spring-petclinic/spring-petclinic-microservices-config) repository and is used in the [Java microservices on AKS](https://azure-samples.github.io/java-microservices-aca-lab/) lab.

docs/02_lab_migrate/0202.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ parent: 'Lab 2: Migrate to Azure Container App'
77

88
# Set up a configuration repository
99

10-
The Spring Petclinic microservices provides a config server that your apps can use. You do need to however provide a git repository for this config server and link this git repo to the server. The current configuration used by the Spring microservices resides in the [config folder of the GitHub repo for this lab](https://github.com/Azure-Samples/java-microservices-aks-lab/tree/main/config). You will need to create your own private git repo in this exercise, since, in one of its steps, you will be changing some of the configuration settings.
10+
The Spring Petclinic microservices provides a config server that your apps can use. You do need to however provide a git repository for this config server and link this git repo to the server. The current configuration used by the Spring microservices resides in the [config folder of the GitHub repo for this lab](https://github.com/Azure-Samples/java-microservices-aca-lab/tree/main/config). You will need to create your own private git repo in this exercise, since, in one of its steps, you will be changing some of the configuration settings.
1111

1212
{: .note }
1313
> We simplified some of the original config of the spring-petclinic-microservices application to make some of the lab steps easier to execute.
@@ -58,17 +58,17 @@ Once you have your own config repository to work with, you will have to update t
5858
{: .note }
5959
> Make sure to replace the `<token>` and `<your-github-username>` placeholders in the URL listed above with the value of the GitHub PAT and your GitHub user name when running the `git clone` command.
6060
61-
1. From the Git Bash prompt, change the current directory to the newly created **spring-petclinic-microservices-config** folder and run the following commands to copy all the config server configuration yaml files from the [config folder of the GitHub repo for this lab](https://github.com/Azure-Samples/java-microservices-aks-lab/tree/main/config) to the local folder on your lab computer.
61+
1. From the Git Bash prompt, change the current directory to the newly created **spring-petclinic-microservices-config** folder and run the following commands to copy all the config server configuration yaml files from the [config folder of the GitHub repo for this lab](https://github.com/Azure-Samples/java-microservices-aca-lab/tree/main/config) to the local folder on your lab computer.
6262

6363
```bash
6464
cd spring-petclinic-microservices-config
65-
curl -o api-gateway.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/api-gateway.yml
66-
curl -o application.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/application.yml
67-
curl -o customers-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/customers-service.yml
68-
curl -o discovery-server.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/discovery-server.yml
69-
curl -o tracing-server.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/tracing-server.yml
70-
curl -o vets-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/vets-service.yml
71-
curl -o visits-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aks-lab/main/config/visits-service.yml
65+
curl -o api-gateway.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/api-gateway.yml
66+
curl -o application.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/application.yml
67+
curl -o customers-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/customers-service.yml
68+
curl -o discovery-server.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/discovery-server.yml
69+
curl -o tracing-server.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/tracing-server.yml
70+
curl -o vets-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/vets-service.yml
71+
curl -o visits-service.yml https://raw.githubusercontent.com/Azure-Samples/java-microservices-aca-lab/main/config/visits-service.yml
7272
```
7373

7474
1. From the Git Bash prompt, run the following commands to commit and push your changes to your private GitHub repository.
@@ -81,7 +81,7 @@ Once you have your own config repository to work with, you will have to update t
8181

8282
1. In your web browser, refresh the page of the newly created _spring-petclinic-microservices-config_ repository and double check that all the configuration files are there.
8383

84-
1. To configure the _spring-petclinic-config-server_ microservice so it points to your GitHub repository, in your _java-microservices-aks-lab_ project navigate to the _spring-petclinic-config-server/src/main/resources/application.yml_ file and update the uri of the git repo to use your own git repo uri. Also add 2 additional settings for your PAT username and password.
84+
1. To configure the _spring-petclinic-config-server_ microservice so it points to your GitHub repository, in your _java-microservices-aca-lab_ project navigate to the _spring-petclinic-config-server/src/main/resources/application.yml_ file and update the uri of the git repo to use your own git repo uri. Also add 2 additional settings for your PAT username and password.
8585

8686
```yml
8787
uri: https://github.com/your-org/your-config-repo-uri

docs/02_lab_migrate/0204.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@ parent: 'Lab 2: Migrate to Azure Container App'
99

1010
As a next step you will need to containerize your different microservice applications. You can do so by using the below starter for containerizing a spring boot application.
1111

12-
- [Configure settings for the Spring Cloud Config Server component in Azure Container Apps](https://github.com/Azure-Samples/java-microservices-aks-lab/compare/main...vermegi:java-microservices-aks-lab:upstream/solution-aca-demo)
13-
- [Connect to a managed Spring Cloud Eureka Server in Azure Container Apps](https://learn.microsoft.com/en-us/azure/container-apps/spring-cloud-eureka-server)
12+
- [Configure settings for the Config Server for Spring component in Azure Container Apps (preview)](https://learn.microsoft.com/azure/container-apps/java-config-server-usage)
13+
- [Tutorial: Connect to a managed Config Server for Spring in Azure Container Apps (preview)](https://learn.microsoft.com/azure/container-apps/java-config-server)
14+
- [Configure settings for the Eureka Server for Spring component in Azure Container Apps (preview)](https://learn.microsoft.com/azure/container-apps/java-eureka-server-usage)
15+
- [Tutorial: Connect to a managed Eureka Server for Spring in Azure Container Apps (preview)](https://learn.microsoft.com/azure/container-apps/spring-cloud-eureka-server)
1416

1517

1618
## Step by step guidance

docs/02_lab_migrate/0206.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ parent: 'Lab 2: Migrate to Azure Container App'
99

1010
Now that you have deployed each of the microservices, you will test them out to see if they were deployed correctly. Also inspect wether all pods are properly up and running. In case they are not, inspect the logs to figure out what might be missing.
1111

12-
- [Get public endpoints](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough#test-the-application)
12+
- [Get public endpoints (THIS LINK IS NOT CORRECT!!!)](https://docs.microsoft.com/en-us/azure/aks/kubernetes-walkthrough#test-the-application)
1313

1414
## Step by step guidance
1515

docs/04_lab_secrets/0401.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,7 @@ The following three apps of your application use the database hosted by the Azur
246246

247247
```bash
248248
249-
cd ~/workspaces/java-microservices-aks-lab/src
249+
cd ~/workspaces/java-microservices-aca-lab/src
250250
mvn clean package -DskipTests
251251
252252
```

index.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,22 @@ layout: home
44
nav_order: 1
55
---
66

7-
# Lab: Deploying and running Java Applications in Azure Kubernetes
7+
# Lab: Deploying and running Java Applications in Azure Container Apps
88

9-
This lab teaches you how to deploy the [Spring Petclinic Microservices](https://github.com/Azure-Samples/java-microservices-aks-lab/tree/main/src) application to an AKS cluster and integrate it with additional Azure services.
9+
This lab teaches you how to deploy the [Spring Petclinic Microservices](https://github.com/Azure-Samples/java-microservices-aca-lab/tree/main/src) application to an Container Apps environment and integrate it with additional Azure services.
1010

1111
## Modules
1212

1313
This lab has modules on:
1414

15-
* Plan a Java application migration to Azure Kubernetes Service
16-
* Migrate a Spring Apps microservices application to Azure Kubernetes Service
15+
* Plan a Java application migration to Azure Container Apps Service
16+
* Migrate a Spring Apps microservices application to Azure Container Apps Service
1717
* Enable monitoring and end-to-end tracing
1818
* Secure application secrets using Key Vault
19-
* Create and configure Azure Service Bus for sending messages between microservices
20-
* Create and configure Azure Event Hubs for sending events between microservices
2119
* Protect endpoints using Web Application Firewalls
2220
* Secure MySQL database and Key Vault using a Private Endpoint
2321

24-
The lab is available as GitHub pages [here](https://azure-samples.github.io/java-microservices-aks-lab/)
22+
The lab is available as GitHub pages [here](https://azure-samples.github.io/java-microservices-aca-lab/)
2523

2624
## Getting Started
2725

install.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ For running this lab with all the needed tooling, there are 3 options available:
1717
1818
## Using a GitHub Codespace
1919

20-
The [git repository of this lab](https://github.com/Azure-Samples/java-microservices-aks-lab) contains a dev container for Java development. This container contains all the needed tools for running this lab. In case you want to use this dev container you can use a [GitHub CodeSpace](https://github.com/features/codespaces) in case your GitHub account is enabled for Codespaces.
20+
The [git repository of this lab](https://github.com/Azure-Samples/java-microservices-aca-lab) contains a dev container for Java development. This container contains all the needed tools for running this lab. In case you want to use this dev container you can use a [GitHub CodeSpace](https://github.com/features/codespaces) in case your GitHub account is enabled for Codespaces.
2121

22-
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aks-lab) and select **Fork**.
22+
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aca-lab) and select **Fork**.
2323

2424
{: .note }
2525
> In case you are using a GitHub EMU account, it might be you are not able to fork a public repository. In that case, create a new repository with the same name, clone the original repository, add your new repository as a remote and push to this new remote.
@@ -38,7 +38,7 @@ The [git repository of this lab](https://github.com/Azure-Samples/java-microserv
3838

3939
## Using Visual Studio Code with remote containers
4040

41-
The [git repository of this lab](https://github.com/Azure-Samples/java-microservices-aks-lab) contains a dev container for Java development. This container contains all the needed tools for running this lab. For this option you need the following tools to be installed on your local system:
41+
The [git repository of this lab](https://github.com/Azure-Samples/java-microservices-aca-lab) contains a dev container for Java development. This container contains all the needed tools for running this lab. For this option you need the following tools to be installed on your local system:
4242

4343
- Visual Studio Code available from [Visual Studio Code Downloads](https://code.visualstudio.com/download)
4444
- Git for Windows 2.3.61 available from [Git Downloads](https://git-scm.com/downloads), or similar on another OS.
@@ -55,7 +55,7 @@ git config --global user.name "<your-full-name>"
5555

5656
To get started follow the below step by step instructions:
5757

58-
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aks-lab) and select **Fork**.
58+
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aca-lab) and select **Fork**.
5959

6060
1. Make sure your own username is indicated as the fork `Owner`
6161

@@ -69,7 +69,7 @@ To get started follow the below step by step instructions:
6969
```bash
7070
mkdir workspaces
7171
cd workspaces
72-
git clone https://github.com/<your-github-account>/java-microservices-aks-lab.git
72+
git clone https://github.com/<your-github-account>/java-microservices-aca-lab.git
7373
```
7474

7575
1. When prompted to sign in to GitHub, select the **Sign in with your browser** option. This will automatically open a new tab in the web browser window, prompting you to provide your GitHub username and password.
@@ -81,10 +81,10 @@ To get started follow the below step by step instructions:
8181
{: .note }
8282
> However in one of the lab steps you will put a GitHub PAT token in one of the configuration files, make sure to **not** commit this PAT token, since it will immediately get invalidated by GitHub. Once invalidated your next lab steps will fail. You can use the [LabTips]({% link LabTips.md %}) to recover from this.
8383
84-
1. Navigate into the `java-microservices-aks-lab/src` folder that got created.
84+
1. Navigate into the `java-microservices-aca-lab/src` folder that got created.
8585

8686
```bash
87-
cd java-microservices-aks-lab/src
87+
cd java-microservices-aca-lab/src
8888
```
8989

9090
1. Open the project with Visual Studio Code
@@ -142,7 +142,7 @@ git config --global user.name "<your-full-name>"
142142

143143
Once all these tools are installed, to get started you need to:
144144

145-
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aks-lab) and select **Fork**.
145+
1. Navigate to the [GitHub repository of this lab](https://github.com/Azure-Samples/java-microservices-aca-lab) and select **Fork**.
146146

147147
{: .note }
148148
> In case you are using a GitHub EMU account, it might be you are not able to fork a public repository. In that case, create a new repository with the same name, clone the original repository, add your new repository as a remote and push to this new remote.
@@ -156,7 +156,7 @@ Once all these tools are installed, to get started you need to:
156156
```bash
157157
mkdir workspaces
158158
cd workspaces
159-
git clone https://github.com/<your-github-account>/java-microservices-aks-lab.git
159+
git clone https://github.com/<your-github-account>/java-microservices-aca-lab.git
160160
```
161161

162162
1. When prompted to sign in to GitHub, select the **Sign in with your browser** option. This will automatically open a new tab in the web browser window, prompting you to provide your GitHub username and password.
@@ -165,10 +165,10 @@ Once all these tools are installed, to get started you need to:
165165

166166
1. In workspaces folder double check that the spring petclinic application got cloned correctly. You can use the repository in your workspaces folder to regularly push your changes to.
167167

168-
1. Navigate into the _java-microservices-aks-lab/src_ folder that got created.
168+
1. Navigate into the _java-microservices-aca-lab/src_ folder that got created.
169169

170170
```bash
171-
cd java-microservices-aks-lab/src
171+
cd java-microservices-aca-lab/src
172172
```
173173

174174
1. Open the project with Visual Studio Code

solution/sampleENVIRONMENT.azcli

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ az acr login --name $MYACR
1010

1111
VIRTUAL_NETWORK_NAME=vnet-$APPNAME-$UNIQUEID
1212
AKS_SUBNET_CIDR=10.1.0.0/24
13-
SUBNET_ID=$(az network vnet subnet show --resource-group $RESOURCE_GROUP --vnet-name $VIRTUAL_NETWORK_NAME --name aks-subnet --query id -o tsv)
14-
AKSCLUSTER=aks-$APPNAME-$UNIQUEID
13+
SUBNET_ID=$(az network vnet subnet show --resource-group $RESOURCE_GROUP --vnet-name $VIRTUAL_NETWORK_NAME --name aca-subnet --query id -o tsv)
14+
ACA_ENVIRONMENT=acaenv-$APPNAME-$UNIQUEID
1515
MYSQL_SERVER_NAME=mysql-$APPNAME-$UNIQUEID
1616
MYSQL_ADMIN_USERNAME=myadmin
1717
MYSQL_ADMIN_PASSWORD=<your-admin-pw>

solution/samplebashrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ MYACR=acr$APPNAME$UNIQUEID
66

77
VIRTUAL_NETWORK_NAME=vnet-$APPNAME-$UNIQUEID
88
AKS_SUBNET_CIDR=10.1.0.0/24
9-
AKSCLUSTER=aks-$APPNAME-$UNIQUEID
9+
ACA_ENVIRONMENT=acaenv-$APPNAME-$UNIQUEID
1010
MYSQL_SERVER_NAME=mysql-$APPNAME-$UNIQUEID
1111
MYSQL_ADMIN_USERNAME=myadmin
1212
MYSQL_ADMIN_PASSWORD=<your-admin-pw>

0 commit comments

Comments
 (0)