1
0
mirror of https://github.com/spantaleev/matrix-docker-ansible-deploy.git synced 2025-06-18 22:17:50 +02:00

Use fully-qualified module names for builtin Ansible modules

Related to https://github.com/spantaleev/matrix-docker-ansible-deploy/pull/1939
This commit is contained in:
Slavi Pantaleev
2022-07-18 10:39:08 +03:00
parent 78b5be4a26
commit 34cdaade08
297 changed files with 1420 additions and 1420 deletions

View File

@ -16,7 +16,7 @@
register: result_pg_old_data_dir_stat
- name: Warn if old Postgres data directory detected
debug:
ansible.builtin.debug:
msg: >
Found that you have Postgres data in `{{ matrix_postgres_base_path }}`.
From now on, Postgres data is supposed to be stored in `{{ matrix_postgres_data_path }}` instead.
@ -26,7 +26,7 @@
# We should stop Postgres first, before building a list of files,
# as to ignore any `postmaster.pid` files, etc.
- name: Ensure matrix-postgres is stopped
service:
ansible.builtin.service:
name: matrix-postgres
state: stopped
daemon_reload: true
@ -41,7 +41,7 @@
when: "result_pg_old_data_dir_stat.stat.exists"
- name: Ensure new Postgres data path exists
file:
ansible.builtin.file:
path: "{{ matrix_postgres_data_path }}"
state: directory
mode: 0700
@ -51,7 +51,7 @@
- block:
- name: Relocate Postgres data files from old directory to new
command: "mv {{ item.path }} {{ matrix_postgres_data_path }}/{{ item.path|basename }}"
ansible.builtin.command: "mv {{ item.path }} {{ matrix_postgres_data_path }}/{{ item.path|basename }}"
with_items: "{{ result_pg_old_data_dir_find.files }}"
when: "result_pg_old_data_dir_stat.stat.exists"
@ -61,12 +61,12 @@
# and have it initialize a new database.
- name: Ensure outdated matrix-postgres.service doesn't exist
file:
ansible.builtin.file:
path: "{{ matrix_systemd_path }}/matrix-postgres.service"
state: absent
when: "result_pg_old_data_dir_stat.stat.exists"
- name: Ensure systemd reloaded after getting rid of outdated matrix-postgres.service
service:
ansible.builtin.service:
daemon_reload: true
when: "result_pg_old_data_dir_stat.stat.exists"