You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/openshift/howto-deploy-java-jboss-enterprise-application-platform-app.md
+18-23Lines changed: 18 additions & 23 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -25,14 +25,9 @@ If you're interested in providing feedback or working closely on your migration
25
25
26
26
- A local developer command line with a UNIX-like command environment - for example, Ubuntu, macOS, or Windows Subsystem for Linux - and Azure CLI installed. To learn how to install the Azure CLI, see [How to install the Azure CLI](/cli/azure/install-azure-cli).
27
27
28
-
> [!NOTE]
29
-
> You can also execute this guidance from the [Azure Cloud Shell](../cloud-shell/get-started/classic.md). This approach has all the prerequisite tools pre-installed.
30
-
>
31
-
> :::image type="icon" source="~/reusable-content/ce-skilling/azure/media/cloud-shell/launch-cloud-shell-button.png" alt-text="Button to launch the Azure Cloud Shell." border="false" link="https://shell.azure.com":::
28
+
- The `mysql` CLI. For example, you can install the CLI by using the following commands on Ubuntu or Debian-based systems:
32
29
33
-
- The `mysql` CLI. You can install the CLI by using the following commands:
34
-
35
-
```azurecli-interactive
30
+
```bash
36
31
sudo apt update
37
32
sudo apt install mysql-server
38
33
```
@@ -146,7 +141,7 @@ The sample is a Java application backed by a MySQL database, and is deployed to
146
141
147
142
Open a shell and set the following environment variables. Replace the substitutions as appropriate.
148
143
149
-
```azurecli-interactive
144
+
```bash
150
145
RG_NAME=<resource-group-name>
151
146
SERVER_NAME=<database-server-name>
152
147
DB_DATABASE_NAME=testdb
@@ -179,7 +174,7 @@ Next, use the following steps to create an Azure Database for MySQL - Flexible S
179
174
180
175
1. Use the following command to create an Azure Database for MySQL - Flexible Server:
181
176
182
-
```azurecli-interactive
177
+
```bash
183
178
az mysql flexible-server create \
184
179
--resource-group ${RG_NAME} \
185
180
--name ${SERVER_NAME} \
@@ -210,7 +205,7 @@ Next, use the following steps to create an Azure Database for MySQL - Flexible S
210
205
211
206
1. Use the following commands to get the host of the created MySQL server:
212
207
213
-
```azurecli-interactive
208
+
```bash
214
209
DB_HOST=$(az mysql flexible-server show \
215
210
--resource-group ${RG_NAME} \
216
211
--name ${SERVER_NAME} \
@@ -223,7 +218,7 @@ Next, use the following steps to create an Azure Database for MySQL - Flexible S
223
218
224
219
1. Use the following command to create a temporary firewall rule to allow connection to the MySQL server from the public internet:
225
220
226
-
```azurecli-interactive
221
+
```bash
227
222
az mysql flexible-server firewall-rule create \
228
223
--resource-group ${RG_NAME} \
229
224
--name ${SERVER_NAME} \
@@ -234,7 +229,7 @@ Next, use the following steps to create an Azure Database for MySQL - Flexible S
234
229
235
230
1. Use the following command to create a new database user with permissions to read and write the specific database. This command is useful to send SQL directly to the database.
236
231
237
-
```azurecli-interactive
232
+
```bash
238
233
mysql --host ${DB_HOST} --user ${ADMIN_USERNAME} --password=${ADMIN_PASSWORD}<<EOF
239
234
CREATE USER '${DB_USERNAME}'@'%' IDENTIFIED BY '${DB_PASSWORD}';
240
235
GRANT ALL PRIVILEGES ON ${DB_DATABASE_NAME} . * TO '${DB_USERNAME}'@'%';
@@ -244,7 +239,7 @@ Next, use the following steps to create an Azure Database for MySQL - Flexible S
244
239
245
240
1. Use the following command to delete the temporary firewall rule:
246
241
247
-
```azurecli-interactive
242
+
```bash
248
243
az mysql flexible-server firewall-rule delete \
249
244
--resource-group ${RG_NAME}\
250
245
--name ${SERVER_NAME}\
@@ -274,7 +269,7 @@ If you navigated away from the **Deployment is in progress** page, the following
274
269
275
270
1. Open the shell, paste the value from the **cmdToGetKubeadminCredentials** field, and execute it. You see the admin account and credential for signing in to the OpenShift cluster console portal. The following example shows an admin account:
276
271
277
-
```azurecli
272
+
```bash
278
273
az aro list-credentials --resource-group eaparo033123rg --name clusterf9e8b9
279
274
```
280
275
@@ -295,7 +290,7 @@ Next, use the following steps to connect to the OpenShift cluster using the Open
295
290
296
291
1. In the shell, use the following commands to download the latest OpenShift 4 CLI for GNU/Linux. If running on an OS other than GNU/Linux, download the appropriate binary for that OS.
@@ -306,7 +301,7 @@ Next, use the following steps to connect to the OpenShift cluster using the Open
306
301
307
302
1. Paste the value from the **cmdToLoginWithKubeadmin** field into the shell, and execute it. You should see the `login successful` message and the project you're using. The following content is an example of the command to connect to the OpenShift cluster using the OpenShift CLI.
308
303
309
-
```azurecli-interactive
304
+
```bash
310
305
oc login \
311
306
$(az aro show \
312
307
--resource-group ${RG_NAME} \
@@ -345,7 +340,7 @@ Use the following steps to deploy the app to the cluster. The app is hosted in t
345
340
346
341
1. In the shell, run the following commands. The commands create a project, apply a permission to enable S2I to work, image the pull secret, and link the secret to the relative service accounts in the project to enable the image pull. Disregard the Git warning about "'detached HEAD' state".
@@ -363,7 +358,7 @@ Use the following steps to deploy the app to the cluster. The app is hosted in t
363
358
364
359
Because the next section uses HEREDOC format, it's best to include and execute it in its own code excerpt.
365
360
366
-
```azurecli-interactive
361
+
```bash
367
362
cat <<EOF | oc apply -f -
368
363
apiVersion: v1
369
364
kind: Secret
@@ -380,14 +375,14 @@ Use the following steps to deploy the app to the cluster. The app is hosted in t
380
375
381
376
You must see `secret/eaparo-sample-pull-secret created` to indicate successful creation of the secret. If you don't see this output, troubleshoot and resolve the problem before proceeding. Finally, link the secret to the default service account for downloading container images so the cluster can run them.
382
377
383
-
```azurecli-interactive
378
+
```bash
384
379
oc secrets link default ${CON_REG_SECRET_NAME} --for=pull
385
380
oc secrets link builder ${CON_REG_SECRET_NAME} --for=pull
386
381
```
387
382
388
383
1. Use the following commands to pull the image stream `jboss-eap74-openjdk11-openshift`. Then, start the source to image process and waituntil it completes.
1. Use the following commands to deploy and run three replicas of the containerized app in the cluster:
418
413
419
-
```azurecli-interactive
414
+
```bash
420
415
cat <<EOF | oc apply -f -
421
416
apiVersion: wildfly.org/v1alpha1
422
417
kind: WildFlyServer
@@ -466,7 +461,7 @@ Next, use the following steps to create a secret:
466
461
467
462
1. Run the following command to return the URL of the application. You can use this URL to access the deployed sample app. Copy the output to the clipboard.
468
463
469
-
```azurecli-interactive
464
+
```bash
470
465
echo http://$(oc get route ${APPLICATION_NAME}-route -o=jsonpath='{.spec.host}')/javaee-cafe
Copy file name to clipboardExpand all lines: articles/openshift/howto-deploy-java-jboss-enterprise-application-platform-with-auto-redeploy.md
+4-5Lines changed: 4 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,10 +36,9 @@ This article uses the Azure Marketplace offer for JBoss EAP to accelerate your j
36
36
37
37
Use the following steps to create a service principal:
38
38
39
-
1. Open the Azure portal and navigate to the Azure Cloud Shell.
40
-
1. Create a service principal by using the following command:
39
+
1. Create a service principal by using the following command on your local terminal:
41
40
42
-
```azurecli
41
+
```bash
43
42
az ad sp create-for-rbac --name "sp-aro-s2i-$(date +%s)"
44
43
```
45
44
@@ -138,9 +137,9 @@ If you navigated away from the **Deployment is in progress** page, use the follo
138
137
139
138
:::image type="content" source="media/howto-deploy-java-jboss-enterprise-application-platform-app/deployment-outputs.png" alt-text="Screenshot of the Azure portal that shows JBoss EAP on Azure Red Hat OpenShift deployment outputs." lightbox="media/howto-deploy-java-jboss-enterprise-application-platform-app/deployment-outputs.png":::
140
139
141
-
1. Open the Azure Cloud Shell, paste the value from the **cmdToGetKubeadminCredentials** field, and execute it. You see the admin account and credential for signing in to the OpenShift cluster console portal. The following example shows an admin account:
140
+
1. Open your local terminal, paste the value from the **cmdToGetKubeadminCredentials** field, and execute it. You see the admin account and credential for signing in to the OpenShift cluster console portal. The following example shows an admin account:
142
141
143
-
```azurecli
142
+
```bash
144
143
az aro list-credentials -g eaparo033123rg -n aro-cluster
Copy file name to clipboardExpand all lines: articles/openshift/howto-deploy-java-liberty-app.md
+3-8Lines changed: 3 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,19 +27,14 @@ If you're interested in providing feedback or working closely on your migration
27
27
- An Azure subscription. [!INCLUDE [quickstarts-free-trial-note](~/reusable-content/ce-skilling/azure/includes/quickstarts-free-trial-note.md)]
28
28
- A local machine with a Unix-like operating system installed (for example, Ubuntu, macOS, or Windows Subsystem for Linux).
29
29
- The [Azure CLI](/cli/azure/install-azure-cli). If you're running on Windows or macOS, consider running Azure CLI in a Docker container. For more information, see [How to run the Azure CLI in a Docker container](/cli/azure/run-azure-cli-docker).
30
-
- Sign in to the Azure CLI by using the [az login](/cli/azure/reference-index#az-login) command. To finish the authentication process, follow the steps displayed in your terminal. For other sign-in options, see [Sign in with the Azure CLI](/cli/azure/authenticate-azure-cli).
31
-
- When you're prompted, install the Azure CLI extension on first use. For more information about extensions, see [Use extensions with the Azure CLI](/cli/azure/azure-cli-extensions-overview).
32
-
- Run [az version](/cli/azure/reference-index?#az-version) to find the version and dependent libraries that are installed. To upgrade to the latest version, run [az upgrade](/cli/azure/reference-index?#az-upgrade). This article requires at least version 2.31.0 of Azure CLI.
30
+
- Sign in to the Azure CLI by using the [az login](/cli/azure/reference-index#az-login) command. To finish the authentication process, follow the steps displayed in your terminal. For other sign-in options, see [Sign into Azure with Azure CLI](/cli/azure/authenticate-azure-cli#sign-into-azure-with-azure-cli).
31
+
- When you're prompted, install the Azure CLI extension on first use. For more information about extensions, see [Use and manage extensions with the Azure CLI](/cli/azure/azure-cli-extensions-overview).
32
+
- Run [az version](/cli/azure/reference-index?#az-version) to find the version and dependent libraries that are installed. To upgrade to the latest version, run [az upgrade](/cli/azure/reference-index?#az-upgrade). This article requires at least version 2.31.0 of Azure CLI.
33
33
- A Java Standard Edition (SE) implementation, version 17 or later (for example, [Eclipse Open J9](https://www.eclipse.org/openj9/)).
34
34
-[Maven](https://maven.apache.org/download.cgi) version 3.5.0 or higher.
35
35
-[Docker](https://docs.docker.com/get-docker/) for your OS.
36
36
- The Azure identity you use to sign in has either the [Contributor](/azure/role-based-access-control/built-in-roles#contributor) role and the [User Access Administrator](/azure/role-based-access-control/built-in-roles#user-access-administrator) role or the [Owner](/azure/role-based-access-control/built-in-roles#owner) role in the current subscription. For an overview of Azure roles, see [What is Azure role-based access control (Azure RBAC)?](/azure/role-based-access-control/overview)
37
37
38
-
> [!NOTE]
39
-
> You can also execute this guidance from the [Azure Cloud Shell](/azure/cloud-shell/quickstart). This approach has all the prerequisite tools pre-installed, with the exception of Docker.
40
-
>
41
-
> :::image type="icon" source="~/reusable-content/ce-skilling/azure/media/cloud-shell/launch-cloud-shell-button.png" alt-text="Button to launch the Azure Cloud Shell." border="false" link="https://shell.azure.com":::
42
-
43
38
## Get a Red Hat pull secret
44
39
45
40
The Azure Marketplace offer you're going to use in this article requires a Red Hat pull secret. This section shows you how to get a Red Hat pull secret for Azure Red Hat OpenShift. To learn about what a Red Hat pull secret is and why you need it, see the [Get a Red Hat pull secret](create-cluster.md#get-a-red-hat-pull-secret-optional) section of [Create an Azure Red Hat OpenShift 4 cluster](create-cluster.md). To get the pull secret for use, follow the steps in this section.
0 commit comments