mariadb.yml aktualisiert

This commit is contained in:
olli 2024-05-26 19:10:20 +02:00
parent 03d47c9bea
commit 2555bc402e

View File

@ -193,30 +193,30 @@
wait_for:
path: /home/docker/mariadb.{{inventory_hostname}}/db-data/ibdata1
- name: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
blockinfile:
path: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
mode: "0500"
owner: root
group: root
create: yes
marker: "# {mark} ANSIBLE MANAGED BLOCK"
block: |
cd /home/docker/mariadb.{{inventory_hostname}}
until wget -t1 --timeout=15 https://mariadb.{{inventory_hostname}} >/dev/null 2>&1
do
sleep 5
done
# [ ...]
backup: yes
validate: /bin/bash -n %s
notify: run mariadb.init
- name: Run mariadb.init after install
ansible.builtin.shell: bash /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
args:
chdir: /home/docker/mariadb.{{inventory_hostname}}
creates: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.log
#- name: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
# blockinfile:
# path: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
# mode: "0500"
# owner: root
# group: root
# create: yes
# marker: "# {mark} ANSIBLE MANAGED BLOCK"
# block: |
# cd /home/docker/mariadb.{{inventory_hostname}}
# until wget -t1 --timeout=15 https://mariadb.{{inventory_hostname}} >/dev/null 2>&1
# do
# sleep 5
# done
# # [ ...]
# backup: yes
# validate: /bin/bash -n %s
# notify: run mariadb.init
#
#- name: Run mariadb.init after install
# ansible.builtin.shell: bash /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.sh
# args:
# chdir: /home/docker/mariadb.{{inventory_hostname}}
# creates: /home/docker/mariadb.{{inventory_hostname}}/mariadb.init.log