mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-02-01 01:28:11 -03:30
Enable ClearLinux as a distro in kubespray (#3855)
Signed-off-by: Ganesh Maharaj Mahalingam <ganesh.mahalingam@intel.com>
This commit is contained in:
committed by
Kubernetes Prow Robot
parent
30a9149b52
commit
73aee004ac
14
roles/bootstrap-os/tasks/bootstrap-clearlinux.yml
Normal file
14
roles/bootstrap-os/tasks/bootstrap-clearlinux.yml
Normal file
@@ -0,0 +1,14 @@
|
||||
---
|
||||
- name: Install basic packages to run containers
|
||||
package:
|
||||
name: "{{ item }}"
|
||||
state: present
|
||||
with_items:
|
||||
- containers-basic
|
||||
|
||||
- name: Make sure docker service is enabled
|
||||
systemd:
|
||||
name: docker
|
||||
enabled: yes
|
||||
daemon_reload: yes
|
||||
state: started
|
||||
@@ -20,6 +20,8 @@
|
||||
centos
|
||||
{%- elif 'OpenSUSE' in os_release.stdout -%}
|
||||
opensuse
|
||||
{%- elif 'Clear Linux OS' in os_release.stdout -%}
|
||||
clearlinux
|
||||
{%- endif -%}
|
||||
|
||||
- include_tasks: bootstrap-ubuntu.yml
|
||||
@@ -40,6 +42,9 @@
|
||||
- include_tasks: bootstrap-opensuse.yml
|
||||
when: os_family == "opensuse"
|
||||
|
||||
- include_tasks: bootstrap-clearlinux.yml
|
||||
when: os_family == "clearlinux"
|
||||
|
||||
- import_tasks: setup-pipelining.yml
|
||||
|
||||
- name: Create remote_tmp for it is used by another module
|
||||
@@ -58,14 +63,14 @@
|
||||
name: "{{inventory_hostname}}"
|
||||
when:
|
||||
- override_system_hostname
|
||||
- ansible_os_family not in ['Suse', 'CoreOS', 'Container Linux by CoreOS']
|
||||
- ansible_os_family not in ['Suse', 'CoreOS', 'Container Linux by CoreOS', 'ClearLinux']
|
||||
|
||||
- name: Assign inventory name to unconfigured hostnames (CoreOS and Tumbleweed only)
|
||||
command: "hostnamectl set-hostname {{inventory_hostname}}"
|
||||
register: hostname_changed
|
||||
when:
|
||||
- override_system_hostname
|
||||
- ansible_os_family in ['Suse', 'CoreOS', 'Container Linux by CoreOS']
|
||||
- ansible_os_family in ['Suse', 'CoreOS', 'Container Linux by CoreOS', 'ClearLinux']
|
||||
|
||||
- name: Update hostname fact (CoreOS and Tumbleweed only)
|
||||
setup:
|
||||
|
||||
Reference in New Issue
Block a user