Constraint for the DB execution.

This commit is contained in:
Andrea Dell'Amico 2021-06-14 18:00:32 +02:00
parent 26d6e535c1
commit 6fc1697a87
Signed by: andrea.dellamico
GPG Key ID: 147ABE6CEB9E20FF
2 changed files with 8 additions and 0 deletions

View File

@ -5,3 +5,4 @@ mei_generator_compose_url: 'https://raw.githubusercontent.com/CMCC-Foundation/bl
#cmmc_mysql_root_password: 'set it in a vault file'
#cmmc_mysql_password: 'set it in a vault file'
#mei_generator_db_constraints: '[node.labels.db_data==mei_generator]'
mei_generator_db_executor: 'docker-exec2.int.d4science.net'

View File

@ -28,6 +28,13 @@
state: absent
delegate_to: localhost
- name: Add the label that will be used as a constraint for the MySQL DB
docker_node:
hostname: '{{ mei_generator_db_executor }}'
labels:
mei_generator_db_data: 'bc_mei_generator'
labels_state: 'merge'
- name: Start the MEI Generator stack
docker_stack:
name: '{{ mei_generator_docker_stack_name }}'