mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-05-08 01:47:37 -02:30
Define and implement specs for bootstrap-os (#4455)
* Add README to bootstrap-os role * Rework bootstrap-os once more * Document workarounds for bugs/deficiencies in Ansible modules * Unify and document role variables * Remove installation of additional packages and repositories * Merge Ubuntu and Debian tasks * Remove pipelining setting from default playbooks * Fix OpenSUSE not running its required tasks
This commit is contained in:
committed by
Kubernetes Prow Robot
parent
d588532c9b
commit
76db060afb
59
roles/bootstrap-os/README.md
Normal file
59
roles/bootstrap-os/README.md
Normal file
@@ -0,0 +1,59 @@
|
||||
# bootstrap-os
|
||||
|
||||
Bootstrap an Ansible host to be able to run Ansible modules.
|
||||
|
||||
This role will:
|
||||
* configure the package manager (if applicable) to be able to fetch packages
|
||||
* install Python
|
||||
* install the necessary packages to use Ansible's package manager modules
|
||||
* set the hostname of the host to `{{ inventory_hostname }}` when requested
|
||||
|
||||
## Requirements
|
||||
|
||||
A host running an operating system that is supported by Kubespray.
|
||||
See https://github.com/kubernetes-sigs/kubespray#supported-linux-distributions for a current list.
|
||||
|
||||
SSH access to the host.
|
||||
|
||||
## Role Variables
|
||||
|
||||
Variables are listed with their default values, if applicable.
|
||||
|
||||
### General variables
|
||||
|
||||
* `http_proxy`/`https_proxy`
|
||||
The role will configure the package manager (if applicable) to download packages via a proxy.
|
||||
This is currently implemented for CentOS/RHEL (`http_proxy` only) as well as Debian and Ubuntu (both `http_proxy` and `https_proxy` are respected)
|
||||
|
||||
* `override_system_hostname: true`
|
||||
The role will set the hostname of the machine to the name it has according to Ansible's inventory (the variable `{{ inventory_hostname }}`).
|
||||
|
||||
### Per distribution variables
|
||||
|
||||
#### CoreOS
|
||||
|
||||
* `coreos_locksmithd_disable: false`
|
||||
Whether `locksmithd` (responsible for rolling restarts) should be disabled or be left alone.
|
||||
|
||||
#### CentOS/RHEL
|
||||
|
||||
* `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.
|
||||
|
||||
- hosts: all
|
||||
gather_facts: false # not all hosts might be able to run modules yet
|
||||
roles:
|
||||
- kubespray-defaults
|
||||
- bootstrap-os
|
||||
|
||||
## License
|
||||
|
||||
Apache 2.0
|
||||
Reference in New Issue
Block a user