Browse Source
fix: Swap kubespray-defaults & boostrap-os (#11441)
- Execute boostrap-os before so that Python is installed for kubespray-defaults
- Remove outdated kubespray-defaults dependency on boostrap-os
pull/11534/head
Kevin Huang
2 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with
1 additions and
10 deletions
-
docs/operating_systems/bootstrap-os.md
-
playbooks/facts.yml
-
roles/kubespray-defaults/tasks/main.yaml
|
|
@ -40,10 +40,6 @@ Variables are listed with their default values, if applicable. |
|
|
|
* `centos_fastestmirror_enabled: false` |
|
|
|
Whether the [fastestmirror](https://wiki.centos.org/PackageManagement/Yum/FastestMirror) yum plugin should be enabled. |
|
|
|
|
|
|
|
## Dependencies |
|
|
|
|
|
|
|
The `kubespray-defaults` role is expected to be run before this role. |
|
|
|
|
|
|
|
## Example Playbook |
|
|
|
|
|
|
|
Remember to disable fact gathering since Python might not be present on hosts. |
|
|
|
|
|
@ -10,8 +10,8 @@ |
|
|
|
# fail. bootstrap-os fixes this on these systems, so in later plays it can be enabled. |
|
|
|
ansible_ssh_pipelining: false |
|
|
|
roles: |
|
|
|
- { role: kubespray-defaults } |
|
|
|
- { role: bootstrap-os, tags: bootstrap-os} |
|
|
|
- { role: kubespray-defaults } |
|
|
|
|
|
|
|
- name: Gather facts |
|
|
|
hosts: k8s_cluster:etcd:calico_rr |
|
|
|
|
|
@ -1,10 +1,5 @@ |
|
|
|
--- |
|
|
|
- name: Set facts variables |
|
|
|
# do not run gather facts when bootstrap-os in roles |
|
|
|
when: > |
|
|
|
ansible_play_role_names | |
|
|
|
intersect(['bootstrap-os', 'kubernetes_sigs.kubespray.bootstrap-os']) | |
|
|
|
length == 0 |
|
|
|
tags: |
|
|
|
- always |
|
|
|
block: |
|
|
|