kolla-ansible/ansible/roles/mariadb/tasks/bootstrap_cluster.yml
Jeffrey Zhang 0fcee87549 map the host localtime to the container
Closes-Bug: #1577148
Change-Id: I636cefc63cf532434a41af3898b63dffa711e280
2016-05-03 09:27:51 +08:00

40 lines
1.2 KiB
YAML

---
- name: Running MariaDB bootstrap container
kolla_docker:
action: "start_container"
common_options: "{{ docker_common_options }}"
detach: False
environment:
KOLLA_BOOTSTRAP:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
DB_ROOT_PASSWORD: "{{ database_password }}"
DB_MAX_TIMEOUT: "{{ database_max_timeout }}"
image: "{{ mariadb_image_full }}"
labels:
BOOTSTRAP:
name: "bootstrap_mariadb"
restart_policy: "never"
volumes:
- "{{ node_config_directory }}/mariadb/:{{ container_config_directory }}/:ro"
- "/etc/localtime:/etc/localtime:ro"
- "kolla_logs:/var/log/kolla/"
- "mariadb:/var/lib/mysql"
- name: Starting first MariaDB container
kolla_docker:
action: "start_container"
common_options: "{{ docker_common_options }}"
environment:
KOLLA_CONFIG_STRATEGY: "{{ config_strategy }}"
BOOTSTRAP_ARGS: "--wsrep-new-cluster"
image: "{{ mariadb_image_full }}"
labels:
BOOTSTRAP:
name: "mariadb"
restart_policy: "never"
volumes:
- "{{ node_config_directory }}/mariadb/:{{ container_config_directory }}/:ro"
- "/etc/localtime:/etc/localtime:ro"
- "kolla_logs:/var/log/kolla/"
- "mariadb:/var/lib/mysql"