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
> This article references CentOS, a Linux distribution that is nearing End Of Life (EOL) status. Please consider your use and plan accordingly. For more information, see the [CentOS End Of Life guidance](/azure/virtual-machines/workloads/centos/centos-end-of-life).
14
14
15
-
This article shows how to install [Ansible](https://docs.ansible.com/) on a Centos VM in Azure.
15
+
This article shows how to install [Ansible](https://docs.ansible.com/) on an Ubuntu VM in Azure.
16
16
17
17
In this article, you learn how to:
18
18
19
19
> [!div class="checklist"]
20
20
> * Create a resource group
21
-
> * Create a CentOS virtual machine
21
+
> * Create an Ubuntu virtual machine
22
22
> * Install Ansible on the virtual machine
23
23
> * Connect to the virtual machine via SSH
24
24
> * Configure Ansible on the virtual machine
@@ -58,7 +58,7 @@ In this article, you learn how to:
58
58
az vm create \
59
59
--resource-group QuickstartAnsible-rg \
60
60
--name QuickstartAnsible-vm \
61
-
--image CentOS85Gen2 \
61
+
--image Ubuntu2204 \
62
62
--admin-username azureuser \
63
63
--admin-password <password>
64
64
```
@@ -75,7 +75,7 @@ In this article, you learn how to:
75
75
New-AzVM `
76
76
-ResourceGroupName QuickstartAnsible-rg `
77
77
-Location eastus `
78
-
-Image CentOS85Gen2 `
78
+
-Image Ubuntu2204 `
79
79
-Name QuickstartAnsible-vm `
80
80
-OpenPorts 22 `
81
81
-Credential $credential
@@ -109,50 +109,26 @@ Replace the `<vm_ip_address>` with the appropriate value returned in previous co
109
109
110
110
## Install Ansible on the virtual machine
111
111
112
-
### Ansible 2.9 with the azure_rm module
112
+
### Ansible with azure.azcollection
113
113
114
-
Run the following commands to configure Ansible 2.9 on Centos:
114
+
Run the following commands to configure Ansible on [Ubuntu](https://docs.ansible.com/ansible/latest/installation_guide/installation_distros.html#installing-ansible-on-ubuntu):
115
115
116
116
```bash
117
117
#!/bin/bash
118
118
119
-
# Update all packages that have available updates.
Copy file name to clipboardExpand all lines: articles/ansible/vm-scale-set-deploy-app.md
-6
Original file line number
Diff line number
Diff line change
@@ -169,12 +169,6 @@ Before running the playbook, see the following notes:
169
169
apt-get install sshpass
170
170
```
171
171
172
-
CentOS:
173
-
174
-
```bash
175
-
yum install sshpass
176
-
```
177
-
178
172
* In some environments, you may see an error about using an SSH password instead of a key. If you do receive that error, you can disable host key checking by adding the following line to `/etc/ansible/ansible.cfg` or `~/.ansible.cfg`:
0 commit comments