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
docs: Replace HTTPS/443 with HTTP/8080 for vm-mgmt testing - Simplifies tutorial by using port 8080 instead of 443 - Removes SSL certificate generation complexity - Makes testing easier without certificate warnings
@@ -438,21 +440,21 @@ az network nsg rule create \
438
440
--destination-port-range 80
439
441
```
440
442
441
-
The following example creates a rule that allows traffic inbound from the Internet to the *asg-mgmt* application security group over port 443:
443
+
The following example creates a rule that allows traffic inbound from the Internet to the *asg-mgmt* application security group over port 8080:
442
444
443
445
```azurecli-interactive
444
446
az network nsg rule create \
445
447
--resource-group test-rg \
446
448
--nsg-name nsg-1 \
447
-
--name Allow-HTTPS-Mgmt \
449
+
--name Allow-8080-Mgmt \
448
450
--access Allow \
449
451
--protocol Tcp \
450
452
--direction Inbound \
451
453
--priority 110 \
452
454
--source-address-prefix Internet \
453
455
--source-port-range "*" \
454
456
--destination-asgs "asg-mgmt" \
455
-
--destination-port-range 443
457
+
--destination-port-range 8080
456
458
```
457
459
458
460
---
@@ -465,7 +467,7 @@ Create two virtual machines (VMs) in the virtual network.
465
467
466
468
1. In the portal, search for and select **Virtual machines**.
467
469
468
-
1. In **Virtual machines**, select **+ Create**, then **Azure virtual machine**.
470
+
1. In **Virtual machines**, select **+ Create**, then **Virtual machine**.
469
471
470
472
1. In **Create a virtual machine**, enter or select this information in the **Basics** tab:
471
473
@@ -830,31 +832,23 @@ az network nic ip-config update \
830
832
831
833
1. Try to access **vm-web** on port 443 by browsing to `https://<public-ip-address-vm-web>` in your browser. The connection fails or times out because the security rule for the **asg-web** doesn't allow port 443 inbound from the internet.
832
834
833
-
1. Now configure **vm-mgmt** with nginx on HTTPS. Select **vm-mgmt** from the **Virtual machines** page.
835
+
1. Now configure **vm-mgmt** with nginx on port 8080. Select **vm-mgmt** from the **Virtual machines** page.
834
836
835
837
1. Select **Run command** from the **Operations** section.
836
838
837
839
1. Select **RunShellScript**.
838
840
839
-
1. In the **Run Command Script** pane, enter the following commands to install nginx with a self-signed certificate for HTTPS:
841
+
1. In the **Run Command Script** pane, enter the following commands to install nginx on port 8080:
index index.html index.htm index.nginx-debian.html;
860
854
server_name _;
@@ -871,9 +865,9 @@ az network nic ip-config update \
871
865
872
866
1. On the **Overview** page of **vm-mgmt**, note the **Public IP address**for your VM.
873
867
874
-
1. To confirm that you can access the **vm-mgmt** web server from the internet on port 443, open an internet browser on your computer and browse to `https://<public-ip-address-vm-mgmt>`.
868
+
1. To confirm that you can access the **vm-mgmt** web server from the internet on port 8080, open an internet browser on your computer and browse to `http://<public-ip-address-vm-mgmt>:8080`.
875
869
876
-
Accept the security warning for the self-signed certificate when prompted. You see the nginx default page because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 443.
870
+
You see the nginx default page because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 8080.
877
871
878
872
1. Try to access **vm-mgmt** on port 80 by browsing to `http://<public-ip-address-vm-mgmt>`in your browser. The connection fails or times out because no security rule allows port 80 inbound to the **asg-mgmt** application security group.
879
873
@@ -917,7 +911,7 @@ You see the nginx default page because inbound traffic from the internet to the
917
911
918
912
Try to access **vm-web** on port 443 by browsing to `https://<vm-web-ip-address>`in your browser. The connection fails or times out because the security rule for the **asg-web** doesn't allow port 443 inbound from the internet.
To confirm that you can access the **vm-mgmt** web server from the internet on port 443, open an internet browser on your computer and browse to `https://<vm-mgmt-ip-address>`.
956
+
To confirm that you can access the **vm-mgmt** web server from the internet on port 8080, open an internet browser on your computer and browse to `http://<vm-mgmt-ip-address>:8080`.
971
957
972
-
Accept the security warning for the self-signed certificate when prompted. You see the nginx default page because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 443.
958
+
You see the nginx default page because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 8080.
973
959
974
960
Try to access **vm-mgmt** on port 80 by browsing to `http://<vm-mgmt-ip-address>` in your browser. The connection fails or times out because no security rule allows port 80 inbound to the **asg-mgmt** application security group.
975
961
@@ -1008,7 +994,7 @@ curl -k https://$webIP
1008
994
1009
995
The connection fails or times out because the security rule for the **asg-web** doesn't allow port 443 inbound from the internet.
1010
996
1011
-
Now install nginx with HTTPS on **vm-mgmt**:
997
+
Now install nginx on port 8080 on **vm-mgmt**:
1012
998
1013
999
```azurecli-interactive
1014
1000
az vm run-command invoke \
@@ -1017,16 +1003,10 @@ az vm run-command invoke \
index index.html index.htm index.nginx-debian.html;
1032
1012
server_name _;
@@ -1045,13 +1025,13 @@ mgmtIP=$(az vm show --show-details --resource-group test-rg --name vm-mgmt --que
1045
1025
echo "vm-mgmt IP: $mgmtIP"
1046
1026
```
1047
1027
1048
-
To confirm that you can access the **vm-mgmt** web server from the internet on port 443, use curl:
1028
+
To confirm that you can access the **vm-mgmt** web server from the internet on port 8080, use curl:
1049
1029
1050
1030
```bash
1051
-
curl -k https://$mgmtIP
1031
+
curl http://$mgmtIP:8080
1052
1032
```
1053
1033
1054
-
The `-k` flag tells curl to ignore the self-signed certificate warning. The connection succeeds because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 443.
1034
+
The connection succeeds because inbound traffic from the internet to the **asg-mgmt** application security group is allowed through port 8080.
1055
1035
1056
1036
Try to access **vm-mgmt** on port 80:
1057
1037
@@ -1097,10 +1077,10 @@ az group delete \
1097
1077
In this tutorial, you:
1098
1078
1099
1079
- Created a network security group and associated it to a virtual network subnet.
1100
-
- Created application security groups for web (HTTP) and management (HTTPS) traffic.
1080
+
- Created application security groups for web and management traffic.
1101
1081
- Created two Linux virtual machines with SSH key authentication and associated their network interfaces with the application security groups.
1102
1082
- Installed nginx web servers on both VMs with different port configurations.
1103
-
- Tested the application security group network filtering by demonstrating that vm-web allows port 80 (HTTP) but denies port 443 (HTTPS), while vm-mgmt allows port 443 (HTTPS) but denies port 80 (HTTP).
1083
+
- Tested the application security group network filtering by demonstrating that vm-web allows port 80 (HTTP) but denies port 443, while vm-mgmt allows port 8080 but denies port 80 (HTTP).
1104
1084
1105
1085
To learn more about network security groups, see [Network security group overview](./network-security-groups-overview.md) and [Manage a network security group](manage-network-security-group.md).
0 commit comments