c12s-kubespray/roles/bootstrap-os/tasks/main.yml

31 lines
616 B
YAML

---
- include: bootstrap-ubuntu.yml
when: bootstrap_os == "ubuntu"
- include: bootstrap-coreos.yml
when: bootstrap_os == "coreos"
- include: bootstrap-centos.yml
when: bootstrap_os == "centos"
- include: setup-pipelining.yml
- name: check if atomic host
stat:
path: /run/ostree-booted
register: ostree
- set_fact:
is_atomic: "{{ ostree.stat.exists }}"
- name: Gather nodes hostnames
setup:
gather_subset: '!all'
filter: ansible_hostname
- name: Assign inventory name to unconfigured hostnames
hostname:
name: "{{inventory_hostname}}"
when: ansible_hostname == 'localhost'