Merge "Move database creation into role"
This commit is contained in:
commit
7871710edf
@ -96,6 +96,8 @@ zun_docker_api_version: false
|
||||
# zun_system_group_gid = <GID>
|
||||
|
||||
## Database info
|
||||
zun_db_setup_host: "{{ ('galera_all' in groups) | ternary(groups['galera_all'][0], 'localhost') }}"
|
||||
zun_galera_address: "{{ galera_address | default('127.0.0.1') }}"
|
||||
zun_galera_user: zun
|
||||
zun_galera_database: zun
|
||||
zun_db_max_overflow: 10
|
||||
|
@ -25,7 +25,7 @@
|
||||
login_host: "{{ zun_galera_address }}"
|
||||
name: "{{ zun_galera_database }}"
|
||||
state: "present"
|
||||
delegate_to: "{{ groups['galera_all'][0] }}"
|
||||
delegate_to: "{{ zun_db_setup_host }}"
|
||||
no_log: True
|
||||
|
||||
- name: Grant access to the DB for the service
|
||||
@ -38,7 +38,8 @@
|
||||
host: "{{ item }}"
|
||||
state: "present"
|
||||
priv: "{{ zun_galera_database }}.*:ALL"
|
||||
append_privs: "{{ db_append_privs | default(omit) }}"
|
||||
delegate_to: "{{ groups['galera_all'][0] }}"
|
||||
with_items: "{{ grant_list | default(['localhost', '%']) }}"
|
||||
delegate_to: "{{ zun_db_setup_host }}"
|
||||
with_items:
|
||||
- "localhost"
|
||||
- "%"
|
||||
no_log: True
|
||||
|
@ -23,7 +23,6 @@
|
||||
zun_service_password: secrete
|
||||
zun_kuryr_service_password: secrete
|
||||
zun_developer_mode: true
|
||||
zun_galera_address: "{{ hostvars[groups['galera_all'][0]]['ansible_host'] }}"
|
||||
zun_rabbitmq_servers: "{{ hostvars[groups['rabbitmq_all'][0]]['ansible_host'] }}"
|
||||
zun_service_publicuri: "http://{{ hostvars[groups['keystone_all'][0]]['ansible_host'] }}:9517"
|
||||
zun_service_adminuri: "http://{{ hostvars[groups['keystone_all'][0]]['ansible_host'] }}:9517"
|
||||
|
Loading…
x
Reference in New Issue
Block a user