
This allows a deployer to customise their inventory at various levels, by providing a custom inventory template for one or more of the sections of the inventory. * Top level groups define the roles of hosts, e.g. controller or compute. * Components define groups of services, e.g. nova or ironic. * Services define single containers, e.g. nova-compute or ironic-api.
51 lines
1.6 KiB
YAML
51 lines
1.6 KiB
YAML
---
|
|
- name: Ensure the Kolla Ansible configuration directores exist
|
|
file:
|
|
path: "{{ item }}"
|
|
state: directory
|
|
owner: "{{ ansible_user }}"
|
|
group: "{{ ansible_user }}"
|
|
mode: 0750
|
|
become: True
|
|
with_items:
|
|
- "{{ kolla_config_path }}"
|
|
- "{{ kolla_config_path }}/inventory"
|
|
- "{{ kolla_node_custom_config_path }}"
|
|
|
|
- name: Ensure the Kolla global configuration file exists
|
|
template:
|
|
src: "globals.yml.j2"
|
|
dest: "{{ kolla_config_path }}/globals.yml"
|
|
mode: 0640
|
|
|
|
# NOTE: We're not looping over the two inventory files to avoid having the file
|
|
# content displayed in the ansible-playbook output.
|
|
|
|
- name: Ensure the Kolla seed inventory file exists
|
|
copy:
|
|
content: "{{ kolla_seed_inventory }}"
|
|
dest: "{{ kolla_config_path }}/inventory/seed"
|
|
mode: 0640
|
|
|
|
- name: Ensure the Kolla overcloud inventory file exists
|
|
copy:
|
|
content: "{{ kolla_overcloud_inventory }}"
|
|
dest: "{{ kolla_config_path }}/inventory/overcloud"
|
|
mode: 0640
|
|
|
|
- name: Ensure the Kolla passwords file exists
|
|
kolla_passwords:
|
|
src: "{{ kayobe_config_path }}/kolla/passwords.yml"
|
|
dest: "{{ kayobe_config_path }}/kolla/passwords.yml"
|
|
mode: 0640
|
|
sample: "{{ kolla_ansible_install_dir }}/etc_examples/kolla/passwords.yml"
|
|
overrides: "{{ kolla_ansible_custom_passwords }}"
|
|
vault_password: "{{ kolla_ansible_vault_password }}"
|
|
virtualenv: "{{ kolla_venv or omit }}"
|
|
|
|
- name: Ensure the Kolla passwords file is copied into place
|
|
copy:
|
|
src: "{{ kayobe_config_path }}/kolla/passwords.yml"
|
|
dest: "{{ kolla_config_path }}/passwords.yml"
|
|
remote_src: True
|