I personally left everything default except username, hostname and the following steps
- SSH Setup stage
- Select Install OpenSSH server
- Select Import SSH identity with selection
from Github
- Input your Github Username (in my case would be
gyurikol
) - I left
unticked
the Allow password authentication over SSH option
... this will install ssh with also adding your Github users Public Keys to the Ubuntu Server under the default users .ssh/authorized_keys
address
If you forget this step you can fetch the ssh keys with the:
ssh-import-id
:- install import id utility
apt-get install ssh-import-id
- fetch github users public keys
ssh-import-id gh:github_username
- install import id utility
- or just
curl
:curl https://github.com/<username>.keys
- Build Ansible Image
docker build --quiet --tag ansible .
- Get Public Key from Ansible Image
docker run --rm --entrypoint "cat" ansible "/home/ansibleuser/.ssh/id_rsa.pub"
- copy output to buffer/clipboard for next step
- Add Public Key to All Hosts you wish to run Ansible Cluster provison against
vi /home/${USER}/.ssh/authorized_keys
-
+ ssh-rsa someFAKEpubKeysomeFAKEpubKey ansibleuser@8906fb83a900 # ansible container
- Update
./host_inventory.yml
- Update Standalone host values if utilizing single & standalone host
- Update Master & Worker hosts if utilizing multiple hosts as master and worker nodes
- Run the
./run.sh
script which will Build and Run the Ansible Docker image to provision Standalone, Master & Worker Kubernetes Node setups.