mirror of
https://github.com/geerlingguy/ansible-role-kubernetes.git
synced 2024-12-21 19:06:56 +01:00
Use same options for all tests and default to Ansible IP correctly.
This commit is contained in:
parent
746e4c07bb
commit
7eea163f81
@ -5,7 +5,7 @@
|
||||
|
||||
vars:
|
||||
# Allow swap in test environments (hard to control in some Docker envs).
|
||||
kubernetes_kubelet_extra_args: "--fail-swap-on=false"
|
||||
kubernetes_kubelet_extra_args: "--fail-swap-on=false --cgroup-driver=cgroupfs"
|
||||
docker_install_compose: false
|
||||
|
||||
pre_tasks:
|
||||
@ -24,11 +24,6 @@
|
||||
- name: Gather facts.
|
||||
action: setup
|
||||
|
||||
- name: Use cgroupfs cgroup driver instead of systemd (RedHat).
|
||||
set_fact:
|
||||
kubernetes_kubelet_extra_args: '"--fail-swap-on=false --cgroup-driver=cgroupfs"'
|
||||
when: ansible_os_family == 'RedHat'
|
||||
|
||||
roles:
|
||||
- role: geerlingguy.docker
|
||||
- role: geerlingguy.kubernetes
|
||||
|
@ -3,7 +3,7 @@
|
||||
command: >
|
||||
kubeadm init
|
||||
--pod-network-cidr={{ kubernetes_pod_network_cidr }}
|
||||
--apiserver-advertise-address={{ kubernetes_apiserver_advertise_address | default(ansible_default_ipv4.address) }}
|
||||
--apiserver-advertise-address={{ kubernetes_apiserver_advertise_address | default(ansible_default_ipv4.address, true) }}
|
||||
--kubernetes-version {{ kubernetes_version_kubeadm }}
|
||||
--ignore-preflight-errors={{ kubernetes_ignore_preflight_errors }}
|
||||
{{ kubernetes_kubeadm_init_extra_opts }}
|
||||
|
Loading…
Reference in New Issue
Block a user