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
1. In this portion of the lab you will re-use a docker-compose.yml file from lab2 to deploy your containers and register with the NGINX One Console. This time you will now add an R34 (latest) version of the NGINX Plus container. Open the docker-compose file in VS Code.
63
-
64
-
```bash
65
-
vi lab5/docker-compose.yml
66
-
67
-
```
71
+
1. In this portion of the lab you will re-use a `docker-compose.yml` file from lab2 to deploy your containers and register with the NGINX One Console. This time you will now add an R34 (latest) version of the NGINX Plus container. Open the docker-compose file in VS Code.
68
72
69
-
After the `plus3` instance code block you will put a new block of code forthe R33 release. You will call this `plus4`, keepingin line with your naming convention for the labs.
73
+
After the `plus3` instance code block you will put a new block of code forthe R34 release. You will call this `plus4`, keepingin line with your naming convention for the labs.
70
74
71
-
Starting on line 75 let's uncomment this block of code (ends on line 96). A little tip, in VS Studio you can highlight the block of code and press `Ctrl` + `/` to uncomment the whole block at once.
75
+
Starting on line 75, let's uncomment this block of code (ends on line 96). A little tip, in VS Studio you can highlight the block of code and press `Ctrl` + `/` to uncomment the whole block at once.
72
76
73
77
```bash
74
78
### Uncomment the section below for Lab5
@@ -77,12 +81,12 @@ Starting with Release 33, NGINX Plus requires NGINX Agent to be installed along
@@ -94,11 +98,12 @@ Starting with Release 33, NGINX Plus requires NGINX Agent to be installed along
94
98
- '9000' # Open for API / Dashboard page
95
99
- '9113' # Open for Prometheus Scraper page
96
100
restart: always
97
-
#
98
101
99
102
```
100
103
101
-
1. Save your edits. You'll notice a couple of changes from the other blocks (besides the name). The first is the environment variable called `NGINX_LICENSE_JWT: $JWT` This is what authorizes the pulling of this specific image. The second change is the image name `private-registry.nginx.com/nginx-plus/agent:debian` which pulls the latest Debian version of NGINX Plus with Agent installed. You will be able to see this in the NGINX One Console once deployed.
104
+
1. Save your edits. You'll notice a couple of changes from the other blocks (besides the name).
105
+
- The first is the environment variable called `NGINX_LICENSE_JWT: $JWT` This is what authorizes the pulling of this specific image.
106
+
- The second change is the image name `private-registry.nginx.com/nginx-plus/agent:r34-debian` which pulls the R34 Debian version of NGINX Plus with Agent installed. You will be able to see this in the NGINX One Console once deployed.
102
107
103
108
1. Now that this file is edited, restart the containers. Issue the following commands:
104
109
@@ -213,7 +218,7 @@ First, you will create a new Config Sync Group to add machines that you want to
213
218
214
219
```
215
220
216
-
1. Set your environment variables:
221
+
1. Set your three environment variables, check them with `echo`:
217
222
218
223
```bash
219
224
export NAME=<YOUR_INITIALS.LASTNAME>
@@ -222,6 +227,14 @@ First, you will create a new Config Sync Group to add machines that you want to
222
227
223
228
```
224
229
230
+
```bash
231
+
echo $NAME
232
+
echo $TOKEN
233
+
echo $JWT
234
+
235
+
```
236
+
237
+
225
238
1. Set the hostname of your Ubuntu VM, so it displays in the NGINX One Console Instances. Use `Nginx123` for the password:
226
239
227
240
```bash
@@ -337,32 +350,32 @@ The NGINX Plus Dashboard and API is where NGINX exposes all of the over 240 metr
337
350
338
351
You can do this in the NGINX One Console - in the Config Sync Group, click on the Configuration tab, then Edit. Click the Add file button, and create `/etc/nginx/conf.d/dashboard.conf`. Use the example provide here, just copy/paste:
339
352
340
-
```nginx
341
-
# NGINX Plus Basics, Nov 2024
342
-
# Chris Akker, Shouvik Dutta, Adam Currier
343
-
# dashboard.conf
344
-
#
345
-
server {
346
-
# Conventional port for the NGINX Plus API is 8080
347
-
listen 9000;
348
-
access_log off;# reduce noise in access logs
349
-
350
-
location /api/ {
351
-
# Enable in read-write mode
352
-
api write=on;
353
-
}
354
-
# Conventional location of the NGINX Plus dashboard
355
-
location = /dashboard.html {
356
-
root /usr/share/nginx/html;
357
-
}
358
-
359
-
# Redirect requests for "/" to "/dashboard.html"
360
-
location / {
361
-
return 301 /dashboard.html;
353
+
```nginx
354
+
# NGINX Plus Basics, Nov 2024
355
+
# Chris Akker, Shouvik Dutta, Adam Currier
356
+
# dashboard.conf
357
+
#
358
+
server {
359
+
# Conventional port for the NGINX Plus API is 8080
360
+
listen 9000;
361
+
access_log off;# reduce noise in access logs
362
+
363
+
location /api/ {
364
+
# Enable in read-write mode
365
+
api write=on;
366
+
}
367
+
# Conventional location of the NGINX Plus dashboard
0 commit comments