added "Flatcar", "Flatcar Container Linux by Kinvolk" for all coreOS role (#5607)
parent
d0d9967457
commit
0ca7aa126b
|
@ -13,7 +13,7 @@
|
||||||
/usr/local/share/ca-certificates/vault-ca.crt
|
/usr/local/share/ca-certificates/vault-ca.crt
|
||||||
{%- elif ansible_os_family == "RedHat" -%}
|
{%- elif ansible_os_family == "RedHat" -%}
|
||||||
/etc/pki/ca-trust/source/anchors/vault-ca.crt
|
/etc/pki/ca-trust/source/anchors/vault-ca.crt
|
||||||
{%- elif ansible_os_family in ["Coreos", "Container Linux by CoreOS"] -%}
|
{%- elif ansible_os_family in ["Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] -%}
|
||||||
/etc/ssl/certs/vault-ca.pem
|
/etc/ssl/certs/vault-ca.pem
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
- name: bootstrap/ca_trust | update ca-certificates (Debian/Ubuntu/CoreOS)
|
- name: bootstrap/ca_trust | update ca-certificates (Debian/Ubuntu/CoreOS)
|
||||||
command: update-ca-certificates
|
command: update-ca-certificates
|
||||||
when: vault_ca_cert.changed and ansible_os_family in ["Debian", "CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: vault_ca_cert.changed and ansible_os_family in ["Debian", "CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: bootstrap/ca_trust | update ca-certificates (RedHat)
|
- name: bootstrap/ca_trust | update ca-certificates (RedHat)
|
||||||
command: update-ca-trust extract
|
command: update-ca-trust extract
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
tags:
|
tags:
|
||||||
- facts
|
- facts
|
||||||
|
|
||||||
- name: Force binaries directory for Container Linux by CoreOS
|
- name: Force binaries directory for Container Linux by CoreOS and Flatcar
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/opt/bin"
|
bin_dir: "/opt/bin"
|
||||||
tags:
|
tags:
|
||||||
|
|
|
@ -14,7 +14,7 @@
|
||||||
when: '"Clear Linux OS" in os_release.stdout'
|
when: '"Clear Linux OS" in os_release.stdout'
|
||||||
|
|
||||||
- include_tasks: bootstrap-coreos.yml
|
- include_tasks: bootstrap-coreos.yml
|
||||||
when: '"CoreOS" in os_release.stdout'
|
when: '"CoreOS" in os_release.stdout or "Flatcar" in os_release.stdout'
|
||||||
|
|
||||||
- include_tasks: bootstrap-debian.yml
|
- include_tasks: bootstrap-debian.yml
|
||||||
when: '"Debian" in os_release.stdout or "Ubuntu" in os_release.stdout'
|
when: '"Debian" in os_release.stdout or "Ubuntu" in os_release.stdout'
|
||||||
|
@ -41,30 +41,30 @@
|
||||||
gather_subset: '!all'
|
gather_subset: '!all'
|
||||||
filter: ansible_*
|
filter: ansible_*
|
||||||
|
|
||||||
- name: Assign inventory name to unconfigured hostnames (non-CoreOS, Suse and ClearLinux)
|
- name: Assign inventory name to unconfigured hostnames (non-CoreOS, non-Flatcar, Suse and ClearLinux)
|
||||||
hostname:
|
hostname:
|
||||||
name: "{{ inventory_hostname }}"
|
name: "{{ inventory_hostname }}"
|
||||||
when:
|
when:
|
||||||
- override_system_hostname
|
- override_system_hostname
|
||||||
- ansible_os_family not in ['Suse', 'Container Linux by CoreOS', 'ClearLinux']
|
- ansible_os_family not in ['Suse', 'Container Linux by CoreOS', 'Flatcar Container Linux by Kinvolk', 'ClearLinux']
|
||||||
|
|
||||||
# (2/3)
|
# (2/3)
|
||||||
- name: Assign inventory name to unconfigured hostnames (CoreOS, Suse and ClearLinux only)
|
- name: Assign inventory name to unconfigured hostnames (CoreOS, non-Flatcar, Suse and ClearLinux only)
|
||||||
command: "hostnamectl set-hostname {{ inventory_hostname }}"
|
command: "hostnamectl set-hostname {{ inventory_hostname }}"
|
||||||
register: hostname_changed
|
register: hostname_changed
|
||||||
changed_when: false
|
changed_when: false
|
||||||
when:
|
when:
|
||||||
- override_system_hostname
|
- override_system_hostname
|
||||||
- ansible_os_family in ['Suse', 'Container Linux by CoreOS', 'ClearLinux']
|
- ansible_os_family in ['Suse', 'Container Linux by CoreOS', 'Flatcar Container Linux by Kinvolk', 'ClearLinux']
|
||||||
|
|
||||||
# (3/3)
|
# (3/3)
|
||||||
- name: Update hostname fact (CoreOS, Suse and ClearLinux only)
|
- name: Update hostname fact (CoreOS, Flatcar, Suse and ClearLinux only)
|
||||||
setup:
|
setup:
|
||||||
gather_subset: '!all'
|
gather_subset: '!all'
|
||||||
filter: ansible_hostname
|
filter: ansible_hostname
|
||||||
when:
|
when:
|
||||||
- override_system_hostname
|
- override_system_hostname
|
||||||
- ansible_os_family in ['Suse', 'Container Linux by CoreOS', 'ClearLinux']
|
- ansible_os_family in ['Suse', 'Flatcar Container Linux by Kinvolk', 'Container Linux by CoreOS', 'ClearLinux']
|
||||||
|
|
||||||
- name: "Install ceph-commmon package"
|
- name: "Install ceph-commmon package"
|
||||||
package:
|
package:
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
service:
|
service:
|
||||||
name: docker.socket
|
name: docker.socket
|
||||||
state: restarted
|
state: restarted
|
||||||
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS']
|
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk']
|
||||||
|
|
||||||
- name: Docker | reload docker
|
- name: Docker | reload docker
|
||||||
service:
|
service:
|
||||||
|
|
|
@ -43,7 +43,7 @@
|
||||||
docker requires a minimum kernel version of
|
docker requires a minimum kernel version of
|
||||||
{{ docker_kernel_min_version }} on
|
{{ docker_kernel_min_version }} on
|
||||||
{{ ansible_distribution }}-{{ ansible_distribution_version }}
|
{{ ansible_distribution }}-{{ ansible_distribution_version }}
|
||||||
when: (not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "ClearLinux"]) and (ansible_kernel is version(docker_kernel_min_version, "<"))
|
when: (not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"]) and (ansible_kernel is version(docker_kernel_min_version, "<"))
|
||||||
tags:
|
tags:
|
||||||
- facts
|
- facts
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@
|
||||||
retries: 4
|
retries: 4
|
||||||
delay: "{{ retry_stagger | d(3) }}"
|
delay: "{{ retry_stagger | d(3) }}"
|
||||||
with_items: "{{ docker_repo_key_info.repo_keys }}"
|
with_items: "{{ docker_repo_key_info.repo_keys }}"
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "RedHat", "Suse", "ClearLinux"] or is_atomic)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "RedHat", "Suse", "ClearLinux"] or is_atomic)
|
||||||
|
|
||||||
- name: ensure docker-ce repository is enabled
|
- name: ensure docker-ce repository is enabled
|
||||||
action: "{{ docker_repo_info.pkg_repo }}"
|
action: "{{ docker_repo_info.pkg_repo }}"
|
||||||
|
@ -68,7 +68,7 @@
|
||||||
repo: "{{ item }}"
|
repo: "{{ item }}"
|
||||||
state: present
|
state: present
|
||||||
with_items: "{{ docker_repo_info.repos }}"
|
with_items: "{{ docker_repo_info.repos }}"
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "RedHat", "Suse", "ClearLinux"] or is_atomic) and (docker_repo_info.repos|length > 0)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "RedHat", "Suse", "ClearLinux"] or is_atomic) and (docker_repo_info.repos|length > 0)
|
||||||
|
|
||||||
- name: ensure docker-engine repository public key is installed
|
- name: ensure docker-engine repository public key is installed
|
||||||
action: "{{ dockerproject_repo_key_info.pkg_key }}"
|
action: "{{ dockerproject_repo_key_info.pkg_key }}"
|
||||||
|
@ -82,7 +82,7 @@
|
||||||
delay: "{{ retry_stagger | d(3) }}"
|
delay: "{{ retry_stagger | d(3) }}"
|
||||||
with_items: "{{ dockerproject_repo_key_info.repo_keys }}"
|
with_items: "{{ dockerproject_repo_key_info.repo_keys }}"
|
||||||
when:
|
when:
|
||||||
- not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "RedHat", "Suse", "ClearLinux"] or is_atomic)
|
- not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "RedHat", "Suse", "ClearLinux"] or is_atomic)
|
||||||
- use_docker_engine is defined and use_docker_engine
|
- use_docker_engine is defined and use_docker_engine
|
||||||
|
|
||||||
- name: ensure docker-engine repository is enabled
|
- name: ensure docker-engine repository is enabled
|
||||||
|
@ -93,7 +93,7 @@
|
||||||
with_items: "{{ dockerproject_repo_info.repos }}"
|
with_items: "{{ dockerproject_repo_info.repos }}"
|
||||||
when:
|
when:
|
||||||
- use_docker_engine is defined and use_docker_engine
|
- use_docker_engine is defined and use_docker_engine
|
||||||
- not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "RedHat", "Suse", "ClearLinux"] or is_atomic) and (dockerproject_repo_info.repos|length > 0)
|
- not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "RedHat", "Suse", "ClearLinux"] or is_atomic) and (dockerproject_repo_info.repos|length > 0)
|
||||||
|
|
||||||
- name: Configure docker repository on Fedora
|
- name: Configure docker repository on Fedora
|
||||||
template:
|
template:
|
||||||
|
@ -162,7 +162,7 @@
|
||||||
delay: "{{ retry_stagger | d(3) }}"
|
delay: "{{ retry_stagger | d(3) }}"
|
||||||
with_items: "{{ docker_package_info.pkgs }}"
|
with_items: "{{ docker_package_info.pkgs }}"
|
||||||
notify: restart docker
|
notify: restart docker
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "ClearLinux"] or is_atomic) and (docker_package_info.pkgs|length > 0)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic) and (docker_package_info.pkgs|length > 0)
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
- name: Ensure docker packages are installed
|
- name: Ensure docker packages are installed
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
dest: /etc/systemd/system/docker.service
|
dest: /etc/systemd/system/docker.service
|
||||||
register: docker_service_file
|
register: docker_service_file
|
||||||
notify: restart docker
|
notify: restart docker
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"] or is_atomic)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] or is_atomic)
|
||||||
|
|
||||||
- name: Write docker options systemd drop-in
|
- name: Write docker options systemd drop-in
|
||||||
template:
|
template:
|
||||||
|
|
|
@ -783,7 +783,7 @@ downloads:
|
||||||
- k8s-cluster
|
- k8s-cluster
|
||||||
|
|
||||||
install_socat:
|
install_socat:
|
||||||
enabled: "{{ ansible_os_family in ['CoreOS', 'Container Linux by CoreOS'] }}"
|
enabled: "{{ ansible_os_family in ['CoreOS', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk'] }}"
|
||||||
container: true
|
container: true
|
||||||
repo: "{{ install_socat_image_repo }}"
|
repo: "{{ install_socat_image_repo }}"
|
||||||
tag: "{{ install_socat_image_tag }}"
|
tag: "{{ install_socat_image_tag }}"
|
||||||
|
|
|
@ -50,7 +50,7 @@
|
||||||
- download_force_cache
|
- download_force_cache
|
||||||
- image_is_cached
|
- image_is_cached
|
||||||
- not download_localhost
|
- not download_localhost
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: download_container | Load image into docker
|
- name: download_container | Load image into docker
|
||||||
shell: "{{ docker_bin_dir }}/docker load < {{ image_path_cached if download_localhost else image_path_final }}"
|
shell: "{{ docker_bin_dir }}/docker load < {{ image_path_cached if download_localhost else image_path_final }}"
|
||||||
|
@ -62,7 +62,7 @@
|
||||||
when:
|
when:
|
||||||
- download_force_cache
|
- download_force_cache
|
||||||
- image_is_cached
|
- image_is_cached
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: download_container | Prepare container download
|
- name: download_container | Prepare container download
|
||||||
include_tasks: check_pull_required.yml
|
include_tasks: check_pull_required.yml
|
||||||
|
@ -109,7 +109,7 @@
|
||||||
when:
|
when:
|
||||||
- download_force_cache
|
- download_force_cache
|
||||||
- not image_is_cached or (image_changed | default(true))
|
- not image_is_cached or (image_changed | default(true))
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: download_container | Copy image to ansible host cache
|
- name: download_container | Copy image to ansible host cache
|
||||||
synchronize:
|
synchronize:
|
||||||
|
@ -123,7 +123,7 @@
|
||||||
- not download_localhost
|
- not download_localhost
|
||||||
- download_delegate == inventory_hostname
|
- download_delegate == inventory_hostname
|
||||||
- not image_is_cached or (image_changed | default(true))
|
- not image_is_cached or (image_changed | default(true))
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: download_container | Remove container image from cache
|
- name: download_container | Remove container image from cache
|
||||||
file:
|
file:
|
||||||
|
@ -131,7 +131,7 @@
|
||||||
path: "{{ image_path_final }}"
|
path: "{{ image_path_final }}"
|
||||||
when:
|
when:
|
||||||
- not download_keep_remote_cache
|
- not download_keep_remote_cache
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
- download
|
- download
|
||||||
|
|
|
@ -67,7 +67,7 @@
|
||||||
when:
|
when:
|
||||||
- download_force_cache
|
- download_force_cache
|
||||||
- file_is_cached
|
- file_is_cached
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: download_file | Set mode and owner
|
- name: download_file | Set mode and owner
|
||||||
file:
|
file:
|
||||||
|
@ -78,7 +78,7 @@
|
||||||
when:
|
when:
|
||||||
- download_force_cache
|
- download_force_cache
|
||||||
- file_is_cached
|
- file_is_cached
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
# This must always be called, to check if the checksum matches. On no-match the file is re-downloaded.
|
# This must always be called, to check if the checksum matches. On no-match the file is re-downloaded.
|
||||||
- name: download_file | Download item
|
- name: download_file | Download item
|
||||||
|
@ -116,7 +116,7 @@
|
||||||
- not file_is_cached or get_url_result.changed
|
- not file_is_cached or get_url_result.changed
|
||||||
- download_delegate == inventory_hostname
|
- download_delegate == inventory_hostname
|
||||||
- not (download_run_once and download_delegate == 'localhost')
|
- not (download_run_once and download_delegate == 'localhost')
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
- download
|
- download
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
mode: 0755
|
mode: 0755
|
||||||
owner: "{{ ansible_ssh_user | default(ansible_user_id) }}"
|
owner: "{{ ansible_ssh_user | default(ansible_user_id) }}"
|
||||||
when:
|
when:
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: prep_download | Create local cache for files and images
|
- name: prep_download | Create local cache for files and images
|
||||||
file:
|
file:
|
||||||
|
|
|
@ -18,12 +18,12 @@
|
||||||
retries: 4
|
retries: 4
|
||||||
delay: "{{ retry_stagger | random + 3 }}"
|
delay: "{{ retry_stagger | random + 3 }}"
|
||||||
when:
|
when:
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: sync_container | Load container image into docker
|
- name: sync_container | Load container image into docker
|
||||||
shell: "{{ docker_bin_dir }}/docker load < {{ image_path_final }}"
|
shell: "{{ docker_bin_dir }}/docker load < {{ image_path_final }}"
|
||||||
when:
|
when:
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: sync_container | Remove container image from cache
|
- name: sync_container | Remove container image from cache
|
||||||
file:
|
file:
|
||||||
|
@ -31,7 +31,7 @@
|
||||||
path: "{{ image_path_final }}"
|
path: "{{ image_path_final }}"
|
||||||
when:
|
when:
|
||||||
- not download_keep_remote_cache
|
- not download_keep_remote_cache
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
tags:
|
tags:
|
||||||
- upload
|
- upload
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
retries: 4
|
retries: 4
|
||||||
delay: "{{ retry_stagger | random + 3 }}"
|
delay: "{{ retry_stagger | random + 3 }}"
|
||||||
when:
|
when:
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: sync_file | Set mode and owner
|
- name: sync_file | Set mode and owner
|
||||||
file:
|
file:
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
dependencies:
|
dependencies:
|
||||||
- role: adduser
|
- role: adduser
|
||||||
user: "{{ addusers.etcd }}"
|
user: "{{ addusers.etcd }}"
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "ClearLinux"] or is_atomic)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic)
|
||||||
- role: adduser
|
- role: adduser
|
||||||
user: "{{ addusers.kube }}"
|
user: "{{ addusers.kube }}"
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "ClearLinux"] or is_atomic)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic)
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
/usr/local/share/ca-certificates/etcd-ca.crt
|
/usr/local/share/ca-certificates/etcd-ca.crt
|
||||||
{%- elif ansible_os_family == "RedHat" -%}
|
{%- elif ansible_os_family == "RedHat" -%}
|
||||||
/etc/pki/ca-trust/source/anchors/etcd-ca.crt
|
/etc/pki/ca-trust/source/anchors/etcd-ca.crt
|
||||||
{%- elif ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"] -%}
|
{%- elif ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] -%}
|
||||||
/etc/ssl/certs/etcd-ca.pem
|
/etc/ssl/certs/etcd-ca.pem
|
||||||
{%- elif ansible_os_family == "Suse" -%}
|
{%- elif ansible_os_family == "Suse" -%}
|
||||||
/etc/pki/trust/anchors/etcd-ca.pem
|
/etc/pki/trust/anchors/etcd-ca.pem
|
||||||
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
- name: Gen_certs | update ca-certificates (Debian/Ubuntu/SUSE/Container Linux by CoreOS)
|
- name: Gen_certs | update ca-certificates (Debian/Ubuntu/SUSE/Container Linux by CoreOS)
|
||||||
command: update-ca-certificates
|
command: update-ca-certificates
|
||||||
when: etcd_ca_cert.changed and ansible_os_family in ["Debian", "CoreOS", "Coreos", "Container Linux by CoreOS", "Suse"]
|
when: etcd_ca_cert.changed and ansible_os_family in ["Debian", "CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "Suse"]
|
||||||
|
|
||||||
- name: Gen_certs | update ca-certificates (RedHat)
|
- name: Gen_certs | update ca-certificates (RedHat)
|
||||||
command: update-ca-trust extract
|
command: update-ca-trust extract
|
||||||
|
|
|
@ -118,7 +118,7 @@ delete the daemonset pod on the relevant host after creating volumes. The pod
|
||||||
will be recreated and read the size correctly.
|
will be recreated and read the size correctly.
|
||||||
|
|
||||||
Make sure to make any mounts persist via /etc/fstab or with systemd mounts (for
|
Make sure to make any mounts persist via /etc/fstab or with systemd mounts (for
|
||||||
CoreOS/Container Linux). Pods with persistent volume claims will not be
|
CoreOS/Container Linux and Flatcar). Pods with persistent volume claims will not be
|
||||||
able to start if the mounts become unavailable.
|
able to start if the mounts become unavailable.
|
||||||
|
|
||||||
Further reading
|
Further reading
|
||||||
|
|
|
@ -35,8 +35,8 @@
|
||||||
retries: 4
|
retries: 4
|
||||||
delay: "{{ retry_stagger | random + 3 }}"
|
delay: "{{ retry_stagger | random + 3 }}"
|
||||||
|
|
||||||
- name: Helm | Copy socat wrapper for Container Linux
|
- name: Helm | Copy socat wrapper for Container Linux and Flatcat
|
||||||
command: "{{ docker_bin_dir }}/docker run --rm -v {{ bin_dir }}:/opt/bin {{ install_socat_image_repo }}:{{ install_socat_image_tag }}"
|
command: "{{ docker_bin_dir }}/docker run --rm -v {{ bin_dir }}:/opt/bin {{ install_socat_image_repo }}:{{ install_socat_image_tag }}"
|
||||||
args:
|
args:
|
||||||
creates: "{{ bin_dir }}/socat"
|
creates: "{{ bin_dir }}/socat"
|
||||||
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS']
|
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk']
|
||||||
|
|
|
@ -113,4 +113,4 @@
|
||||||
shell: "umask 022 && {{ bin_dir }}/helm completion bash >/etc/bash_completion.d/helm.sh"
|
shell: "umask 022 && {{ bin_dir }}/helm completion bash >/etc/bash_completion.d/helm.sh"
|
||||||
when:
|
when:
|
||||||
- ((helm_container is defined and helm_container.changed) or (helm_task_result is defined and helm_task_result.changed))
|
- ((helm_container is defined and helm_container.changed) or (helm_task_result is defined and helm_task_result.changed))
|
||||||
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
|
@ -50,4 +50,4 @@
|
||||||
command: "{{ docker_bin_dir }}/docker run --rm -v {{ bin_dir }}:/opt/bin {{ install_socat_image_repo }}:{{ install_socat_image_tag }}"
|
command: "{{ docker_bin_dir }}/docker run --rm -v {{ bin_dir }}:/opt/bin {{ install_socat_image_repo }}:{{ install_socat_image_tag }}"
|
||||||
args:
|
args:
|
||||||
creates: "{{ bin_dir }}/socat"
|
creates: "{{ bin_dir }}/socat"
|
||||||
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS']
|
when: ansible_os_family in ['CoreOS', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk']
|
||||||
|
|
|
@ -9,18 +9,18 @@
|
||||||
- Preinstall | restart kube-controller-manager crio/containerd
|
- Preinstall | restart kube-controller-manager crio/containerd
|
||||||
- Preinstall | restart kube-apiserver docker
|
- Preinstall | restart kube-apiserver docker
|
||||||
- Preinstall | restart kube-apiserver crio/containerd
|
- Preinstall | restart kube-apiserver crio/containerd
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Preinstall | update resolvconf for Container Linux by CoreOS
|
- name: Preinstall | update resolvconf for Container Linux by CoreOS and Flatcar
|
||||||
command: /bin/true
|
command: /bin/true
|
||||||
notify:
|
notify:
|
||||||
- Preinstall | apply resolvconf cloud-init
|
- Preinstall | apply resolvconf cloud-init
|
||||||
- Preinstall | reload kubelet
|
- Preinstall | reload kubelet
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Preinstall | apply resolvconf cloud-init
|
- name: Preinstall | apply resolvconf cloud-init
|
||||||
command: /usr/bin/coreos-cloudinit --from-file {{ resolveconf_cloud_init_conf }}
|
command: /usr/bin/coreos-cloudinit --from-file {{ resolveconf_cloud_init_conf }}
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Preinstall | reload kubelet
|
- name: Preinstall | reload kubelet
|
||||||
service:
|
service:
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
- name: Stop if unknown OS
|
- name: Stop if unknown OS
|
||||||
assert:
|
assert:
|
||||||
that: ansible_os_family in ['RedHat', 'CentOS', 'Fedora', 'Ubuntu', 'Debian', 'CoreOS', 'Coreos', 'Container Linux by CoreOS', 'Suse', 'ClearLinux', 'OracleLinux']
|
that: ansible_os_family in ['RedHat', 'CentOS', 'Fedora', 'Ubuntu', 'Debian', 'CoreOS', 'Coreos', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk', 'Suse', 'ClearLinux', 'OracleLinux']
|
||||||
msg: "{{ ansible_os_family }} is not a known OS"
|
msg: "{{ ansible_os_family }} is not a known OS"
|
||||||
ignore_errors: "{{ ignore_assert_errors }}"
|
ignore_errors: "{{ ignore_assert_errors }}"
|
||||||
|
|
||||||
|
|
|
@ -15,10 +15,10 @@
|
||||||
{{ ansible_architecture }}
|
{{ ansible_architecture }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
- name: Force binaries directory for Container Linux by CoreOS
|
- name: Force binaries directory for Container Linux by CoreOS and Flatcar
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/opt/bin"
|
bin_dir: "/opt/bin"
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
tags:
|
tags:
|
||||||
- facts
|
- facts
|
||||||
|
|
||||||
|
@ -85,12 +85,12 @@
|
||||||
{%- if resolvconf|bool -%}/etc/resolvconf/resolv.conf.d/base{%- endif -%}
|
{%- if resolvconf|bool -%}/etc/resolvconf/resolv.conf.d/base{%- endif -%}
|
||||||
head: >-
|
head: >-
|
||||||
{%- if resolvconf|bool -%}/etc/resolvconf/resolv.conf.d/head{%- endif -%}
|
{%- if resolvconf|bool -%}/etc/resolvconf/resolv.conf.d/head{%- endif -%}
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: target temporary resolvconf cloud init file (Container Linux by CoreOS)
|
- name: target temporary resolvconf cloud init file (Container Linux by CoreOS)
|
||||||
set_fact:
|
set_fact:
|
||||||
resolvconffile: /tmp/resolveconf_cloud_init_conf
|
resolvconffile: /tmp/resolveconf_cloud_init_conf
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: check if /etc/dhclient.conf exists
|
- name: check if /etc/dhclient.conf exists
|
||||||
stat:
|
stat:
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
---
|
---
|
||||||
- name: create temporary resolveconf cloud init file
|
- name: create temporary resolveconf cloud init file
|
||||||
command: cp -f /etc/resolv.conf "{{ resolvconffile }}"
|
command: cp -f /etc/resolv.conf "{{ resolvconffile }}"
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Add domain/search/nameservers/options to resolv.conf
|
- name: Add domain/search/nameservers/options to resolv.conf
|
||||||
blockinfile:
|
blockinfile:
|
||||||
|
@ -47,7 +47,7 @@
|
||||||
- name: get temporary resolveconf cloud init file content
|
- name: get temporary resolveconf cloud init file content
|
||||||
command: cat {{ resolvconffile }}
|
command: cat {{ resolvconffile }}
|
||||||
register: cloud_config
|
register: cloud_config
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: persist resolvconf cloud init file
|
- name: persist resolvconf cloud init file
|
||||||
template:
|
template:
|
||||||
|
@ -56,4 +56,4 @@
|
||||||
owner: root
|
owner: root
|
||||||
mode: 0644
|
mode: 0644
|
||||||
notify: Preinstall | update resolvconf for Container Linux by CoreOS
|
notify: Preinstall | update resolvconf for Container Linux by CoreOS
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
|
@ -79,7 +79,7 @@
|
||||||
until: pkgs_task_result is succeeded
|
until: pkgs_task_result is succeeded
|
||||||
retries: 4
|
retries: 4
|
||||||
delay: "{{ retry_stagger | random + 3 }}"
|
delay: "{{ retry_stagger | random + 3 }}"
|
||||||
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "ClearLinux"] or is_atomic)
|
when: not (ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk", "ClearLinux"] or is_atomic)
|
||||||
tags:
|
tags:
|
||||||
- bootstrap-os
|
- bootstrap-os
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
backup: yes
|
backup: yes
|
||||||
when:
|
when:
|
||||||
- disable_ipv6_dns
|
- disable_ipv6_dns
|
||||||
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
tags:
|
tags:
|
||||||
- bootstrap-os
|
- bootstrap-os
|
||||||
|
|
||||||
|
|
|
@ -69,7 +69,7 @@
|
||||||
when:
|
when:
|
||||||
- dns_mode != 'none'
|
- dns_mode != 'none'
|
||||||
- resolvconf_mode == 'host_resolvconf'
|
- resolvconf_mode == 'host_resolvconf'
|
||||||
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
tags:
|
tags:
|
||||||
- bootstrap-os
|
- bootstrap-os
|
||||||
- resolvconf
|
- resolvconf
|
||||||
|
@ -78,7 +78,7 @@
|
||||||
when:
|
when:
|
||||||
- dns_mode != 'none'
|
- dns_mode != 'none'
|
||||||
- resolvconf_mode != 'host_resolvconf'
|
- resolvconf_mode != 'host_resolvconf'
|
||||||
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
tags:
|
tags:
|
||||||
- bootstrap-os
|
- bootstrap-os
|
||||||
- resolvconf
|
- resolvconf
|
||||||
|
|
|
@ -419,7 +419,7 @@ proxy_env:
|
||||||
|
|
||||||
ssl_ca_dirs: >-
|
ssl_ca_dirs: >-
|
||||||
[
|
[
|
||||||
{% if ansible_os_family in ['CoreOS', 'Container Linux by CoreOS'] -%}
|
{% if ansible_os_family in ['CoreOS', 'Container Linux by CoreOS', 'Flatcar', 'Flatcar Container Linux by Kinvolk'] -%}
|
||||||
'/usr/share/ca-certificates',
|
'/usr/share/ca-certificates',
|
||||||
{% elif ansible_os_family == 'RedHat' -%}
|
{% elif ansible_os_family == 'RedHat' -%}
|
||||||
'/etc/pki/tls',
|
'/etc/pki/tls',
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
command: /bin/true
|
command: /bin/true
|
||||||
notify:
|
notify:
|
||||||
- Macvlan | reload network
|
- Macvlan | reload network
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Macvlan | reload network
|
- name: Macvlan | reload network
|
||||||
service:
|
service:
|
||||||
|
@ -16,4 +16,4 @@
|
||||||
networking
|
networking
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
state: restarted
|
state: restarted
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"] and kube_network_plugin not in ['canal', 'calico']
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] and kube_network_plugin not in ['canal', 'calico']
|
||||||
|
|
|
@ -75,14 +75,14 @@
|
||||||
template:
|
template:
|
||||||
src: coreos-service-nat_ouside.j2
|
src: coreos-service-nat_ouside.j2
|
||||||
dest: /etc/systemd/system/enable_nat_ouside.service
|
dest: /etc/systemd/system/enable_nat_ouside.service
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"] and enable_nat_default_gateway
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] and enable_nat_default_gateway
|
||||||
|
|
||||||
- name: Macvlan | Enable service nat via gateway on coreos
|
- name: Macvlan | Enable service nat via gateway on coreos
|
||||||
command: "{{ item }}"
|
command: "{{ item }}"
|
||||||
with_items:
|
with_items:
|
||||||
- systemctl daemon-reload
|
- systemctl daemon-reload
|
||||||
- systemctl enable enable_nat_ouside.service
|
- systemctl enable enable_nat_ouside.service
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"] and enable_nat_default_gateway
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"] and enable_nat_default_gateway
|
||||||
|
|
||||||
- name: Macvlan | Install network gateway interface on coreos
|
- name: Macvlan | Install network gateway interface on coreos
|
||||||
template:
|
template:
|
||||||
|
@ -93,7 +93,7 @@
|
||||||
- {src: coreos-interface-macvlan.cfg, dst: output.network }
|
- {src: coreos-interface-macvlan.cfg, dst: output.network }
|
||||||
- {src: coreos-network-macvlan.cfg, dst: macvlan.network }
|
- {src: coreos-network-macvlan.cfg, dst: macvlan.network }
|
||||||
notify: Macvlan | restart network
|
notify: Macvlan | restart network
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Macvlan | Install cni definition for Macvlan
|
- name: Macvlan | Install cni definition for Macvlan
|
||||||
template:
|
template:
|
||||||
|
|
|
@ -302,7 +302,7 @@
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
state: restarted
|
state: restarted
|
||||||
when:
|
when:
|
||||||
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
- ansible_os_family not in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
- reset_restart_network
|
- reset_restart_network
|
||||||
tags:
|
tags:
|
||||||
- services
|
- services
|
||||||
|
|
|
@ -2,15 +2,15 @@
|
||||||
- hosts: kube-master[0]
|
- hosts: kube-master[0]
|
||||||
tasks:
|
tasks:
|
||||||
|
|
||||||
- name: Force binaries directory for Container Linux by CoreOS
|
- name: Force binaries directory for Container Linux by CoreOS and Flatcar
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/opt/bin"
|
bin_dir: "/opt/bin"
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Force binaries directory for other hosts
|
- name: Force binaries directory for other hosts
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/usr/local/bin"
|
bin_dir: "/usr/local/bin"
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Check kubectl output
|
- name: Check kubectl output
|
||||||
shell: "{{ bin_dir }}/kubectl get pods --all-namespaces -owide"
|
shell: "{{ bin_dir }}/kubectl get pods --all-namespaces -owide"
|
||||||
|
|
|
@ -5,15 +5,15 @@
|
||||||
test_image_tag: latest
|
test_image_tag: latest
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: Force binaries directory for Container Linux by CoreOS
|
- name: Force binaries directory for Container Linux by CoreOS and Flatcar
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/opt/bin"
|
bin_dir: "/opt/bin"
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Force binaries directory for other hosts
|
- name: Force binaries directory for other hosts
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/usr/local/bin"
|
bin_dir: "/usr/local/bin"
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Create test namespace
|
- name: Create test namespace
|
||||||
shell: "{{ bin_dir }}/kubectl create namespace test"
|
shell: "{{ bin_dir }}/kubectl create namespace test"
|
||||||
|
|
|
@ -14,15 +14,15 @@
|
||||||
netchecker_port: 31081
|
netchecker_port: 31081
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: Force binaries directory for Container Linux by CoreOS
|
- name: Force binaries directory for Container Linux by CoreOS and Flatcar
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/opt/bin"
|
bin_dir: "/opt/bin"
|
||||||
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Force binaries directory on other hosts
|
- name: Force binaries directory on other hosts
|
||||||
set_fact:
|
set_fact:
|
||||||
bin_dir: "/usr/local/bin"
|
bin_dir: "/usr/local/bin"
|
||||||
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS"]
|
when: not ansible_os_family in ["CoreOS", "Coreos", "Container Linux by CoreOS", "Flatcar", "Flatcar Container Linux by Kinvolk"]
|
||||||
|
|
||||||
- name: Wait for netchecker server
|
- name: Wait for netchecker server
|
||||||
shell: "{{ bin_dir }}/kubectl get pods -o wide --namespace {{ netcheck_namespace }} | grep ^netchecker-server"
|
shell: "{{ bin_dir }}/kubectl get pods -o wide --namespace {{ netcheck_namespace }} | grep ^netchecker-server"
|
||||||
|
|
Loading…
Reference in New Issue