mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-03-07 02:27:43 +03:00
Implemented cloud-provider integration for OpenStack.
Currently kubespray does not install kubernetes in a way that allows cinder volumes to be used. This commit provides the necessary cloud configuration file and configures kubelet and kube-apiserver to use it.
This commit is contained in:
@@ -48,8 +48,11 @@
|
||||
|
||||
- name: check cloud_provider value
|
||||
fail:
|
||||
msg: "If set the 'cloud_provider' var must be set eithe to 'gce' or 'aws'"
|
||||
when: cloud_provider is defined and cloud_provider not in ['gce', 'aws']
|
||||
msg: "If set the 'cloud_provider' var must be set either to 'gce', 'aws' or 'openstack'"
|
||||
when: cloud_provider is defined and cloud_provider not in ['gce', 'aws', 'openstack']
|
||||
|
||||
- include: openstack-credential-check.yml
|
||||
when: cloud_provider is defined and cloud_provider == 'openstack'
|
||||
|
||||
- name: Create cni directories
|
||||
file:
|
||||
@@ -105,4 +108,12 @@
|
||||
when: ansible_os_family == "RedHat"
|
||||
changed_when: False
|
||||
|
||||
- name: Write openstack cloud-config
|
||||
template:
|
||||
src: openstack-cloud-config.j2
|
||||
dest: "{{ kube_config_dir }}/cloud_config"
|
||||
group: "{{ kube_cert_group }}"
|
||||
mode: 0640
|
||||
when: cloud_provider is defined and cloud_provider == "openstack"
|
||||
|
||||
- include: etchosts.yml
|
||||
|
||||
Reference in New Issue
Block a user