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: content/learning-paths/servers-and-cloud-computing/nginx-on-azure/_index.md
+10-14Lines changed: 10 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,23 +1,19 @@
1
1
---
2
-
title: Deploy NGINX on the Microsoft Azure Cobalt 100 processors
2
+
title: Deploy NGINX on Azure Cobalt 100 Arm-based virtual machines
3
3
4
-
draft: true
5
-
cascade:
6
-
draft: true
7
-
8
4
minutes_to_complete: 30
9
5
10
-
who_is_this_for: This Learning Path introduces NGINX deployment on Microsoft Azure Cobalt 100 (Arm-based) virtual machine. It is intended for system administrators and developers looking to deploy and benchmark NGINX on Arm-based instances.
6
+
who_is_this_for: This is an introductory topic for system administrators and developers who want to learn how to deploy and benchmark NGINX on Microsoft Azure Cobalt 100 Arm-based instances.
11
7
12
8
learning_objectives:
13
-
- Start an Azure Arm64 virtual machine using the Azure console and Ubuntu Pro 24.04 LTS as the base image.
14
-
- Deploy the NGINX web server on the Azure Arm64 virtual machine.
15
-
- Configure and test a static website using NGINX on the virtual machine.
16
-
- Perform baseline testing and benchmarking of NGINX in the Ubuntu Pro 24.04 LTS Arm64 virtual machine environment.
9
+
- Create an Arm64 virtual machine on Azure Cobalt 100 (Dpsv6) using the Azure console with Ubuntu Pro 24.04 LTS as the base image
10
+
- Install and configure the NGINX web server on the Azure Arm64 virtual machine
11
+
- Configure and test a static website with NGINX on the virtual machine
12
+
- Run baseline NGINX performance tests with ApacheBench (ab) on Ubuntu Pro 24.04 LTS Arm64
17
13
18
14
19
15
prerequisites:
20
-
- A [Microsoft Azure](https://azure.microsoft.com/) account with access to Cobalt 100 based instances (Dpsv6).
16
+
- A [Microsoft Azure](https://azure.microsoft.com/) account with access to Cobalt 100 based instances (Dpsv6)
Azure’s Cobalt 100 is built on Microsoft's first-generation, in-house Arm-based processor: the Cobalt 100. Designed entirely by Microsoft and based on Arm’s Neoverse N2 architecture, this 64-bit CPU delivers improved performance and energy efficiency across a broad spectrum of cloud-native, scale-out Linux workloads. These include web and application servers, data analytics, open-source databases, caching systems, and more. Running at 3.4GHz, the Cobalt 100 processor allocates a dedicated physical core for each vCPU, ensuring consistent and predictable performance.
11
+
Azure’s Cobalt 100 is Microsoft’s first-generation, in-house Arm-based processor. Built on Arm Neoverse N2, Cobalt 100 is a 64-bit CPU that delivers strong performance and energy efficiency for cloud-native, scale-out Linux workloads such as web and application servers, data analytics, open-source databases, and caching systems. Running at 3.4GHz, Cobalt 100 allocates a dedicated physical core for each vCPU, which helps ensure consistent and predictable performance.
12
12
13
-
To learn more about Cobalt 100, refer to the blog [Announcing the preview of new Azure virtual machine based on the Azure Cobalt 100 processor](https://techcommunity.microsoft.com/blog/azurecompute/announcing-the-preview-of-new-azure-vms-based-on-the-azure-cobalt-100-processor/4146353).
13
+
To learn more, see the Microsoft blog [Announcing the preview of new Azure VMs based on the Azure Cobalt 100 processor](https://techcommunity.microsoft.com/blog/azurecompute/announcing-the-preview-of-new-azure-vms-based-on-the-azure-cobalt-100-processor/4146353).
14
14
15
15
## NGINX
16
16
17
-
NGINX is a high-performance, open-source web server, reverse proxy, load balancer, and HTTP cache. Originally developed by Igor Sysoev, NGINX is known for its event-driven, asynchronous architecture, which enables it to handle high concurrency with low resource usage.
17
+
NGINX is a high-performance open-source web server, reverse proxy, load balancer, and HTTP cache. Known for its event-driven, asynchronous architecture, NGINX handles high concurrency with low resource usage.
18
18
19
19
There are three main variants of NGINX:
20
-
-**NGINX Open Source**– Free and [open-source version available at nginx.org](https://nginx.org)
21
-
-**NGINX Plus**- [Commercial edition of NGINX](https://www.nginx.com/products/nginx/) with features like dynamic reconfig, active health checks, and monitoring.
22
-
-**NGINX Unit**- A lightweight, dynamic application server that complements NGINX. [Learn more at unit.nginx.org](https://unit.nginx.org/).
20
+
- Open source NGINX: a free and [open-source version available at nginx.org](https://nginx.org)
21
+
- NGINX Plus: a [Commercial edition of NGINX](https://www.nginx.com/products/nginx/) with features like dynamic reconfig, active health checks, and monitoring
22
+
- NGINX Unit: a lightweight, dynamic application server that complements NGINX - find out more at the [NGINX website](https://unit.nginx.org/)
Copy file name to clipboardExpand all lines: content/learning-paths/servers-and-cloud-computing/nginx-on-azure/baseline.md
+29-45Lines changed: 29 additions & 45 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,21 +6,20 @@ weight: 5
6
6
layout: learningpathall
7
7
---
8
8
9
+
## Baseline test NGINX with a static website
9
10
10
-
### Baseline testing with a static website on NGINX
11
-
Once NGINX is installed and serving the default welcome page, the next step is to verify that it can serve your own content. A baseline test using a simple static HTML site ensures that NGINX is correctly configured and working as expected on your Ubuntu Pro 24.04 LTS virtual machine.
11
+
Once NGINX is installed and serving the default welcome page, verify that it can serve your own content. A baseline test with a simple static HTML site confirms that NGINX is correctly configured and working as expected on your Ubuntu Pro 24.04 LTS virtual machine.
12
12
13
-
1. Create a Static Website Directory:
14
-
15
-
Prepare a folder to host your HTML content.
13
+
## Create a static website directory
14
+
Prepare a folder to host your HTML content:
16
15
```console
17
16
mkdir -p /var/www/my-static-site
18
17
cd /var/www/my-static-site
19
18
```
20
-
2. Create an HTML file and Web page:
21
19
22
-
Create a simple HTML file to replace the default NGINX welcome page. Using a file editor of your choice create the file `index.html` with the content below:
20
+
## Create an HTML file
23
21
22
+
Create a simple HTML page to replace the default NGINX welcome page. Using a file editor of your choice, create `index.html` with the following content:
24
23
```html
25
24
<!DOCTYPE html>
26
25
<htmllang="en">
@@ -56,30 +55,25 @@ Create a simple HTML file to replace the default NGINX welcome page. Using a fil
56
55
</head>
57
56
<body>
58
57
<divclass="box">
59
-
<h1>Welcome to NGINX on Azure Ubuntu Pro 24.04 LTS!</h1>
60
-
<p>Your static site is running beautifully on ARM64 </p>
58
+
<h1>Welcome to NGINX on Azure Ubuntu Pro 24.04 LTS!</h1>
59
+
<p>Your static site is running beautifully on Arm64</p>
61
60
</div>
62
61
</body>
63
62
</html>
64
63
```
65
-
3. Adjust Permissions:
66
-
67
-
Ensure that NGINX (running as the www-data user) can read the files in your custom site directory:
68
64
65
+
## Adjust permissions
66
+
Ensure that NGINX (running as the `www-data` user) can read the files in your custom site directory:
This sets the ownership of the directory and files so that the NGINX process can serve them without permission issues.
73
-
74
-
4. Update NGINX Configuration:
75
-
76
-
Point NGINX to serve files from your new directory by creating a dedicated configuration file under /etc/nginx/conf.d/.
77
70
71
+
## Update NGINX configuration
72
+
Point NGINX to serve files from your new directory by creating a dedicated configuration file under `/etc/nginx/conf.d/`:
78
73
```console
79
74
sudo nano /etc/nginx/conf.d/static-site.conf
80
75
```
81
-
Add the following configuration to it:
82
-
76
+
Add the following configuration:
83
77
```console
84
78
server {
85
79
listen 80 default_server;
@@ -97,54 +91,44 @@ server {
97
91
error_log /var/log/nginx/static-error.log;
98
92
}
99
93
```
100
-
This configuration block tells NGINX to:
101
-
- Listen on port 80 (both IPv4 and IPv6).
102
-
- Serve files from /var/www/my-static-site.
103
-
- Use index.html as the default page.
104
-
- Log access and errors to dedicated log files for easier troubleshooting.
94
+
This server block listens on port 80 for both IPv4 and IPv6, serves files from `/var/www/my-static-site/`, and uses `index.html` as the default page. It also writes access and error events to dedicated log files to simplify troubleshooting.
105
95
96
+
{{% notice Note %}}
106
97
Make sure the path to your `index.html` file is correct before saving.
98
+
{{% /notice %}}
107
99
108
-
5. Disable the default site:
109
-
110
-
By default, NGINX comes with a packaged default site configuration. Since you have created a custom config, it is good practice to disable the default to avoid conflicts:
111
-
100
+
## Disable the default site
101
+
NGINX ships with a packaged default site configuration. Since you created a custom config, disable the default to avoid conflicts:
112
102
```console
113
103
sudo unlink /etc/nginx/sites-enabled/default
114
104
```
115
105
116
-
6. Test the NGINX Configuration:
117
-
118
-
Before applying your changes, always test the configuration to make sure there are no syntax errors:
119
-
106
+
## Test the NGINX configuration
107
+
Before applying your changes, test the configuration for syntax errors:
120
108
```console
121
109
sudo nginx -t
122
110
```
123
-
You should see output similar to:
111
+
Expected output:
124
112
```output
125
113
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
126
114
nginx: configuration file /etc/nginx/nginx.conf test is successful
127
115
```
128
-
If you see both lines, your configuration is valid.
129
-
130
-
7. Reload or Restart NGINX:
131
116
132
-
After testing the configuration, apply your changes by reloading or restarting the NGINX service:
117
+
## Reload or restart NGINX
118
+
Apply your changes by reloading or restarting the NGINX service:
133
119
```console
134
120
sudo nginx -s reload
135
121
sudo systemctl restart nginx
136
122
```
137
123
138
-
8. Test the Static Website in a browser:
139
-
140
-
Access your website at your public IP on port 80.
141
-
124
+
## Test the static website in a browser
125
+
Access your website at your public IP on port 80:
142
126
```console
143
127
http://<your-vm-public-ip>/
144
128
```
145
129
146
-
9. You should see the NGINX welcome page confirming a successful deployment:
You should see your custom page instead of the default welcome page:
132
+

149
133
150
-
This verifies the basic functionality of NGINX installation and you can now proceed to benchmarking the performance of NGINX on your Arm-based Azure VM.
134
+
This verifies the basic functionality of the NGINX installation. You can now proceed to benchmarking NGINX performance on your Arm-based Azure VM.
0 commit comments