Convert Keystone to kolla_docker
Change-Id: Ia1beaf8205317f8c628fa1efcb65be90a9ad8237 Partially-Implements: blueprint kolla-docker-module
This commit is contained in:
parent
9e5e51dead
commit
bc1cc939d2
@ -37,41 +37,18 @@
|
||||
run_once: True
|
||||
delegate_to: "{{ groups['keystone'][0] }}"
|
||||
|
||||
- name: Starting Keystone bootstrap container
|
||||
docker:
|
||||
tty: True
|
||||
- name: Running Keystone bootstrap container
|
||||
kolla_docker:
|
||||
action: "start_container"
|
||||
common_options: "{{ docker_common_options }}"
|
||||
detach: False
|
||||
net: host
|
||||
pull: "{{ docker_pull_policy }}"
|
||||
restart_policy: "no"
|
||||
state: reloaded
|
||||
registry: "{{ docker_registry }}"
|
||||
username: "{{ docker_registry_username }}"
|
||||
password: "{{ docker_registry_password }}"
|
||||
insecure_registry: "{{ docker_insecure_registry }}"
|
||||
name: bootstrap_keystone
|
||||
image: "{{ keystone_image_full }}"
|
||||
volumes: "{{ node_config_directory }}/keystone/:{{ container_config_directory }}/:ro"
|
||||
env:
|
||||
environment:
|
||||
KOLLA_BOOTSTRAP:
|
||||
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
|
||||
run_once: True
|
||||
delegate_to: "{{ groups['keystone'][0] }}"
|
||||
when: database_created
|
||||
|
||||
# https://github.com/ansible/ansible-modules-core/pull/1031
|
||||
- name: Waiting for Keystone bootstrap container to exit
|
||||
command: docker wait bootstrap_keystone
|
||||
register: bootstrap_result
|
||||
run_once: True
|
||||
failed_when: bootstrap_result.stdout != "0"
|
||||
delegate_to: "{{ groups['keystone'][0] }}"
|
||||
when: database_created
|
||||
|
||||
- name: Cleaning up Keystone bootstrap container
|
||||
docker:
|
||||
name: bootstrap_keystone
|
||||
image: "{{ keystone_image_full }}"
|
||||
state: absent
|
||||
name: "bootstrap_keystone"
|
||||
restart_policy: "never"
|
||||
volumes: "{{ node_config_directory }}/keystone/:{{ container_config_directory }}/:ro"
|
||||
run_once: True
|
||||
delegate_to: "{{ groups['keystone'][0] }}"
|
||||
when: database_created
|
||||
|
@ -1,23 +1,13 @@
|
||||
---
|
||||
- name: Starting Keystone container
|
||||
docker:
|
||||
tty: True
|
||||
net: host
|
||||
pull: "{{ docker_pull_policy }}"
|
||||
restart_policy: "{{ docker_restart_policy }}"
|
||||
restart_policy_retry: "{{ docker_restart_policy_retry }}"
|
||||
state: reloaded
|
||||
registry: "{{ docker_registry }}"
|
||||
username: "{{ docker_registry_username }}"
|
||||
password: "{{ docker_registry_password }}"
|
||||
insecure_registry: "{{ docker_insecure_registry }}"
|
||||
name: keystone
|
||||
- name: Starting keystone container
|
||||
kolla_docker:
|
||||
action: "start_container"
|
||||
common_options: "{{ docker_common_options }}"
|
||||
image: "{{ keystone_image_full }}"
|
||||
name: "keystone"
|
||||
volumes:
|
||||
- "{{ node_config_directory }}/keystone/:{{ container_config_directory }}/:ro"
|
||||
- "/var/lib/kolla/dev/log:/dev/log"
|
||||
env:
|
||||
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
|
||||
|
||||
- name: Wait for keystone startup
|
||||
wait_for: host={{ keystone_admin_address }} port={{ keystone_admin_port }}
|
||||
|
Loading…
x
Reference in New Issue
Block a user