Skip to content

Commit 0ae677b

Browse files
author
Cephas Lin
committed
team review
1 parent 4570170 commit 0ae677b

8 files changed

+10
-14
lines changed
81.7 KB
Loading
56.5 KB
Loading
126 KB
Loading
109 KB
Loading
31.2 KB
Loading
66.1 KB
Loading
82 KB
Loading

articles/app-service/tutorial-java-tomcat-mysql-app.md

Lines changed: 10 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -46,14 +46,14 @@ azd up
4646

4747
## 1. Run the sample
4848

49-
For your convenience, the [sample repository](https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app), includes a [dev container](https://docs.github.com/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers) configuration. The dev container has everything you need to develop an application, including the database, cache, and all environment variables needed by the sample application. The dev container can run in a [GitHub codespace](https://docs.github.com/en/codespaces/overview), which means you can run the sample on any computer with a web browser.
49+
First, you set up a sample data-driven app as a starting point. For your convenience, the [sample repository](https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app), includes a [dev container](https://docs.github.com/codespaces/setting-up-your-project-for-codespaces/adding-a-dev-container-configuration/introduction-to-dev-containers) configuration. The dev container has everything you need to develop an application, including the database, cache, and all environment variables needed by the sample application. The dev container can run in a [GitHub codespace](https://docs.github.com/en/codespaces/overview), which means you can run the sample on any computer with a web browser.
5050

5151
:::row:::
5252
:::column span="2":::
5353
**Step 1:** In a new browser window:
5454
1. Sign in to your GitHub account.
55-
1. Navigate to [https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app](https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app).
56-
1. Select **Fork**.
55+
1. Navigate to [https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app/fork](https://github.com/Azure-Samples/msdocs-tomcat-mysql-sample-app/fork).
56+
1. Unselect **Copy the main branch only**. You want all the branches.
5757
1. Select **Create fork**.
5858
:::column-end:::
5959
:::column:::
@@ -62,7 +62,9 @@ For your convenience, the [sample repository](https://github.com/Azure-Samples/m
6262
:::row-end:::
6363
:::row:::
6464
:::column span="2":::
65-
**Step 2:** In the GitHub fork, select **Code** > **Create codespace on main**.
65+
**Step 2:** In the GitHub fork:
66+
1. Select **main** > **starter-no-infra** for the starter branch. This branch contains just the sample project and no Azure-related files or configuration.
67+
1. Select **Code** > **Create codespace on main**.
6668
The codespace takes a few minutes to set up.
6769
:::column-end:::
6870
:::column:::
@@ -219,7 +221,8 @@ Like the Tomcat convention, if you want to deploy to the root context of Tomcat,
219221
1. Sign in to your GitHub account and follow the prompt to authorize Azure.
220222
1. In **Organization**, select your account.
221223
1. In **Repository**, select **msdocs-tomcat-mysql-sample-app**.
222-
1. In **Branch**, select **main**.
224+
1. In **Branch**, select **starter-no-infra**. This is the same branch that you worked in with your sample app, without any Azure-related files or configuration.
225+
1. For **Authentication type**, select **User-assigned identity**.
223226
1. In the top menu, select **Save**. App Service commits a workflow file into the chosen GitHub repository, in the `.github/workflows` directory.
224227
By default, the deployment center [creates a user-assigned identity](#i-dont-have-permissions-to-create-a-user-assigned-identity) for the workflow to authenticate using Microsoft Entra (OIDC authentication). For alternative authentication options, see [Deploy to App Service using GitHub Actions](deploy-github-actions.md).
225228
:::column-end:::
@@ -229,7 +232,7 @@ Like the Tomcat convention, if you want to deploy to the root context of Tomcat,
229232
:::row-end:::
230233
:::row:::
231234
:::column span="2":::
232-
**Step 3:** Back in the GitHub codespace of your sample fork, run `git pull origin main`.
235+
**Step 3:** Back in the GitHub codespace of your sample fork, run `git pull origin starter-no-infra`.
233236
This pulls the newly committed workflow file into your codespace.
234237
:::column-end:::
235238
:::column:::
@@ -372,14 +375,7 @@ When you're finished, you can delete all of the resources from your Azure subscr
372375

373376
In this step, you create the Azure resources and deploy a sample app to App Service on Linux. The steps used in this tutorial create a set of secure-by-default resources that include App Service and Azure Database for MySQL.
374377

375-
1. In the GitHub codspace of your sample fork, get the remote `starter-no-infra` branch by running the following code in the terminal.
376-
377-
```bash
378-
git fetch upstream
379-
git checkout -b starter-no-infra upstream/starter-no-infra
380-
```
381-
382-
This branch is your starting point. It contains a simple data-drive Tomcat application.
378+
The dev container already has the [Azure Developer CLI](/azure/developer/azure-developer-cli/install-azd).
383379

384380
1. From the repository root, run `azd init`.
385381

0 commit comments

Comments
 (0)