* Add the option for specifying an SSH key. * Add ability to specify SSH key. * Update config.sample.yaml * Update config.sample.yaml * Update bootstrap/templates/ansible/inventory/hosts.yaml.j2 * Update bootstrap/templates/ansible/inventory/hosts.yaml.j2 --------- Co-authored-by: Devin Buhl <onedr0p@users.noreply.github.com>
30 lines
919 B
YAML
30 lines
919 B
YAML
---
|
|
kubernetes:
|
|
children:
|
|
controllers:
|
|
hosts:
|
|
#% for item in bootstrap_node_inventory %#
|
|
#% if item.controller %#
|
|
"#{ item.name }#":
|
|
ansible_user: "#{ item.ssh_user }#"
|
|
ansible_host: "#{ item.address }#"
|
|
#% if item.ssh_key %#
|
|
ansible_ssh_private_key_file: "#{ item.ssh_key }#"
|
|
#% endif %#
|
|
#% endif %#
|
|
#% endfor %#
|
|
#% if bootstrap_node_inventory | selectattr('controller', 'equalto', False) | list | length %#
|
|
workers:
|
|
hosts:
|
|
#% for item in bootstrap_node_inventory %#
|
|
#% if not item.controller %#
|
|
"#{ item.name }#":
|
|
ansible_user: "#{ item.ssh_user }#"
|
|
ansible_host: "#{ item.address }#"
|
|
#% if item.ssh_key %#
|
|
ansible_ssh_private_key_file: "#{ item.ssh_key }#"
|
|
#% endif %#
|
|
#% endif %#
|
|
#% endfor %#
|
|
#% endif %#
|