openshift-labs / learn-katacoda

The OpenShift learning portal, powered by Katacoda
https://learn.openshift.com
159 stars 266 forks source link

host01 unreachable in "Ansible Refresher" Scenario #1120

Open dcurran90 opened 3 years ago

dcurran90 commented 3 years ago

Just following along the scenario here https://learn.openshift.com/ansibleop/ansible-refresher/ and can't get past the first page as "host01" seems to not be available. Not sure if the host isn't created, dns isn't set or what

mgoerens commented 3 years ago

I'm experiencing a similar issue today, on Step 1 of the Ansible Refresher scenario:

$ echo "[group1]" > myhosts
$ echo "host01 ansible_ssh_user=cent" >> myhosts
$ cat myhosts
[group1]
host01 ansible_ssh_user=cent
$ ansible all -i myhosts -m ping
host01 | UNREACHABLE! => {
    "changed": false, 
    "msg": "Failed to connect to the host via ssh: ssh: Could not resolve hostname host01: Name or service not known\r\n", 
    "unreachable": true
}
$ cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
127.0.0.1 master
172.17.0.8 master
172.30.166.125 ocp-registry