!chore: Migrate to docker_compose_v2

This now uses the new docker compose plugin.
Because we used docker-compose v1.24.1 to this point due to centos needing to install C toolchains to build never versions, the newest Docker v25 breaks compatibility and we need to use something newer.
This commit is contained in:
saibotk 2024-02-22 00:37:48 +01:00
parent 5e76d89a2a
commit 70341479b1
Signed by: saibotk
GPG key ID: 67585F0065E261D5
33 changed files with 325 additions and 330 deletions

View file

@ -21,9 +21,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ camo_install_location }}"
become: true
@ -34,9 +34,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ camo_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -44,10 +44,10 @@
become: true
- name: Compose camo container
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ camo_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- camo

View file

@ -21,7 +21,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item.location }}(/.*)?'
target: "{{ item.location }}(/.*)?"
setype: "container_file_t"
selevel: "{{ item.selevel | default(omit) }}"
state: present
@ -40,9 +40,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ codimd_install_location }}"
tags:
@ -70,9 +70,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ codimd_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -80,10 +80,10 @@
become: true
- name: Compose codimd
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ codimd_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- codimd

View file

@ -21,9 +21,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ docker_ipv6_nat_install_location }}"
tags:
@ -34,9 +34,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ docker_ipv6_nat_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -44,10 +44,10 @@
become: true
- name: Compose docker-ipv6-nat
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ docker_ipv6_nat_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -32,9 +32,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ factorio_install_location }}"
become: true
@ -45,9 +45,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0750'
owner: '845'
group: '845'
mode: "0750"
owner: "845"
group: "845"
setype: "container_file_t"
with_items:
- "{{ factorio_data_location }}"
@ -59,9 +59,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ factorio_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -69,10 +69,10 @@
become: true
- name: Compose factorio container
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ factorio_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- factorio

View file

@ -20,7 +20,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -38,9 +38,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ gitlab_install_location }}"
tags:
@ -51,8 +51,8 @@
ansible.builtin.file: # noqa risky-file-permissions # Container manages permissions on its own
path: "{{ item }}"
state: directory
owner: 'root'
group: 'root'
owner: "root"
group: "root"
setype: "container_file_t"
with_items:
- "{{ gitlab_data_location }}"
@ -67,9 +67,9 @@
ansible.builtin.template:
src: telegraf.conf
dest: "{{ gitlab_telegraf_location }}/telegraf.conf"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
tags:
- telegraf
- gitlab
@ -81,9 +81,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ gitlab_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -91,10 +91,10 @@
become: true
- name: Compose GitLab
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ gitlab_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- gitlab

View file

@ -76,10 +76,10 @@
become: true
- name: Compose gitlab-runner
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ gitlab_runner_config_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- gitlab-runner

View file

@ -21,7 +21,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
selevel: "{{ keycloak_postgres_selinux_level }}"
state: present
@ -33,9 +33,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ keycloak_install_location }}"
tags:
@ -58,9 +58,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ keycloak_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -68,10 +68,10 @@
become: true
- name: Compose keycloak
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ keycloak_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- keycloak

View file

@ -8,8 +8,7 @@
become: true
- name: Stop mastodon for upgrade
community.docker.docker_compose:
state: present
community.docker.docker_compose_v2:
state: stopped
project_src: "{{ mastodon_install_location }}"
stopped: true
become: true

View file

@ -21,7 +21,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -36,9 +36,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ mastodon_install_location }}"
become: true
@ -61,15 +61,15 @@
path: "{{ mastodon_elastic_location }}"
state: directory
setype: "container_file_t"
mode: '0750'
mode: "0750"
owner: 1000
group: 'root'
group: "root"
become: true
- name: Adjust sysctl settings for elasticsearch
ansible.posix.sysctl:
name: vm.max_map_count
value: '262144'
value: "262144"
state: present
when:
- mastodon_config.enable_elasticsearch is defined and mastodon_config.enable_elasticsearch
@ -79,9 +79,9 @@
- name: Create public data directory
ansible.builtin.file:
path: "{{ mastodon_public_location }}/system"
mode: '0755'
owner: '991'
group: '991'
mode: "0755"
owner: "991"
group: "991"
state: directory
setype: "container_file_t"
become: true
@ -90,9 +90,9 @@
ansible.builtin.template:
src: "default.conf"
dest: "{{ mastodon_nginx_location }}/default.conf"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
become: true
- name: Check if migration is needed
@ -111,9 +111,9 @@
ansible.builtin.template:
src: ".env.production"
dest: "{{ mastodon_install_location }}/.env.production"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
tags:
- mastodon
become: true
@ -122,9 +122,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ mastodon_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- mastodon
@ -161,10 +161,10 @@
PYTHONPATH: ""
- name: Compose mastodon
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ mastodon_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -22,7 +22,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -36,9 +36,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ matrix_install_location }}"
become: true
@ -57,9 +57,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ matrix_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- matrix
@ -87,10 +87,10 @@
- not matrix_synapse_homeserver_yaml.stat.exists
- name: Compose matrix
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -19,12 +19,11 @@
#
- name: Restart matrix delegate nginx
community.docker.docker_compose:
community.docker.docker_compose_v2:
services:
- delegate
state: present
state: restarted
project_src: "{{ matrix_delegate_install_location }}"
restarted: true
tags:
- docker
- matrix

View file

@ -24,9 +24,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ matrix_delegate_install_location }}"
become: true
@ -35,9 +35,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ matrix_delegate_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- matrix
@ -49,9 +49,9 @@
src: "{{ item }}"
dest: "{{ matrix_delegate_install_location }}/{{ item }}"
setype: "container_file_t"
mode: '0644'
owner: 'root'
group: 'root'
mode: "0644"
owner: "root"
group: "root"
with_items:
- "server-delegation.json"
- "client-delegation.json"
@ -66,9 +66,9 @@
src: "delegate-nginx.conf"
dest: "{{ matrix_delegate_install_location }}/nginx.conf"
setype: "container_file_t"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
tags:
- docker
- matrix
@ -77,10 +77,10 @@
become: true
- name: Compose matrix_delegate
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_delegate_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -19,12 +19,11 @@
#
- name: Restart matrix elementweb
community.docker.docker_compose:
community.docker.docker_compose_v2:
services:
- elementweb
state: present
state: restarted
project_src: "{{ matrix_elementweb_install_location }}"
restarted: true
tags:
- docker
- matrix

View file

@ -22,7 +22,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -35,9 +35,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ matrix_elementweb_install_location }}"
become: true
@ -55,9 +55,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ matrix_elementweb_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- matrix
@ -69,9 +69,9 @@
src: "{{ item }}"
dest: "{{ matrix_elementweb_data_location }}/{{ item }}"
setype: "container_file_t"
mode: '0644'
owner: '991'
group: '991'
mode: "0644"
owner: "991"
group: "991"
with_items:
- "config.json"
tags:
@ -82,10 +82,10 @@
become: true
- name: Compose matrix-elementweb
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_elementweb_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -22,7 +22,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -36,9 +36,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ matrix_maubot_install_location }}"
become: true
@ -57,9 +57,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ matrix_maubot_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- matrix
@ -67,10 +67,10 @@
become: true
- name: Compose matrix-maubot
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_maubot_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -66,10 +66,10 @@
become: true
- name: Compose matrix_sliding_sync
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_sliding_sync_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -19,12 +19,11 @@
#
- name: Restart matrix webhooks
community.docker.docker_compose:
community.docker.docker_compose_v2:
services:
- appservice-webhooks
state: present
state: restarted
project_src: "{{ matrix_webhooks_install_location }}"
restarted: true
tags:
- docker
- matrix

View file

@ -22,7 +22,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -33,9 +33,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ matrix_webhooks_install_location }}"
become: true
@ -53,9 +53,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ matrix_webhooks_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- matrix
@ -67,9 +67,9 @@
src: "{{ item }}"
dest: "{{ matrix_webhooks_data_location }}/{{ item }}"
setype: "container_file_t"
mode: '0640'
owner: 'root'
group: 'root'
mode: "0640"
owner: "root"
group: "root"
with_items:
- "database.json"
- "config.yaml"
@ -90,10 +90,10 @@
become: true
- name: Compose matrix-webhooks
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ matrix_webhooks_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -18,8 +18,8 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
- name: Restart telegraf
community.docker.docker_compose:
community.docker.docker_compose_v2:
services: "telegraf"
project_src: "{{ minecraft_install_location }}"
restarted: true
state: restarted
become: true

View file

@ -20,7 +20,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -34,9 +34,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ minecraft_install_location }}"
become: true
@ -59,7 +59,7 @@
- name: Create telegraf config directory
ansible.builtin.file:
path: "{{ item }}"
mode: '0700'
mode: "0700"
owner: "{{ minecraft_telegraf_config_uid }}"
group: "{{ minecraft_telegraf_config_gid }}"
state: directory
@ -72,7 +72,7 @@
ansible.builtin.template:
src: telegraf.conf
dest: "{{ minecraft_telegraf_location }}/telegraf.conf"
mode: '0600'
mode: "0600"
owner: "{{ minecraft_telegraf_config_uid }}"
group: "{{ minecraft_telegraf_config_gid }}"
notify: "Restart telegraf"
@ -87,9 +87,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ minecraft_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -100,18 +100,18 @@
ansible.builtin.template:
src: minecraftctl.sh
dest: "/usr/local/bin/minecraftctl"
mode: '0755'
owner: 'root'
group: 'root'
mode: "0755"
owner: "root"
group: "root"
tags:
- minecraft
become: true
- name: Compose minecraft
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ minecraft_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- minecraft

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -31,9 +31,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ minecraft_blockmap_install_location }}"
become: true
@ -44,9 +44,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0755'
owner: 'root'
group: 'root'
mode: "0755"
owner: "root"
group: "root"
setype: "container_file_t"
with_items:
- "{{ minecraft_blockmap_output_location }}"
@ -59,9 +59,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0755'
owner: 'root'
group: 'root'
mode: "0755"
owner: "root"
group: "root"
with_items:
- "{{ minecraft_blockmap_archive_location }}"
become: true
@ -72,18 +72,18 @@
ansible.builtin.template:
src: "default.conf"
dest: "{{ minecraft_blockmap_install_location }}/default.conf"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
become: true
- name: Deploy blockmap config
ansible.builtin.template:
src: "blockmap.json"
dest: "{{ minecraft_blockmap_config_location }}/blockmap.json"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
setype: "container_file_t"
become: true
@ -91,9 +91,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ minecraft_blockmap_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -104,9 +104,9 @@
ansible.builtin.file:
path: "/blockmap_snapshot"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
recurse: true
become: true
@ -114,7 +114,7 @@
ansible.builtin.template:
src: "{{ item.src }}"
dest: "{{ item.dest }}"
mode: '0700'
mode: "0700"
owner: root
group: root
with_items:
@ -126,7 +126,7 @@
ansible.builtin.template:
src: "{{ item }}"
dest: /etc/systemd/system/
mode: '0755'
mode: "0755"
owner: root
group: root
with_items:
@ -139,15 +139,15 @@
ansible.builtin.systemd:
daemon_reload: true
name: blockmap-render.timer
enabled: '{{ minecraft_blockmap_timer_enabled | bool }}'
state: '{{ minecraft_blockmap_timer_state }}'
enabled: "{{ minecraft_blockmap_timer_enabled | bool }}"
state: "{{ minecraft_blockmap_timer_state }}"
become: true
- name: Compose minecraft-blockmap
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ minecraft_blockmap_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- blockmap

View file

@ -20,7 +20,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -33,9 +33,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ minio_install_location }}"
become: true
@ -46,9 +46,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
setype: "container_file_t"
with_items:
- "{{ minio_data_location }}"
@ -60,9 +60,9 @@
ansible.builtin.file:
path: "{{ minio_data_location }}/{{ item.key }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_dict:
- "{{ minio_users }}"
tags:
@ -74,9 +74,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ minio_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -86,10 +86,10 @@
- minio_users | length > 0
- name: Compose minio
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ minio_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- minio

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -31,9 +31,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ monitoring_install_location }}"
become: true
@ -42,9 +42,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0750'
owner: '472'
group: '472'
mode: "0750"
owner: "472"
group: "472"
setype: "container_file_t"
with_items:
- "{{ monitoring_grafana_location }}"
@ -54,9 +54,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0750'
owner: 'root'
group: 'root'
mode: "0750"
owner: "root"
group: "root"
setype: "container_file_t"
with_items:
- "{{ monitoring_influxdb_location }}"
@ -66,17 +66,17 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ monitoring_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
become: true
- name: Compose monitoring
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ monitoring_install_location }}"
pull: true
pull: always
remove_orphans: true
register: monitoring_compose
become: true

View file

@ -19,12 +19,11 @@
#
- name: Restart owncast
community.docker.docker_compose:
community.docker.docker_compose_v2:
services:
- owncast
state: present
state: restarted
project_src: "{{ owncast_install_location }}"
restarted: true
tags:
- docker
- owncast

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -30,9 +30,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ owncast_install_location }}"
become: true
@ -43,9 +43,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0750'
owner: 'root'
group: 'root'
mode: "0750"
owner: "root"
group: "root"
setype: "container_file_t"
with_items:
- "{{ owncast_config_location }}"
@ -57,9 +57,9 @@
ansible.builtin.template:
src: "config.yaml"
dest: "{{ owncast_config_location }}/config.yaml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
setype: "container_file_t"
notify: Restart owncast
become: true
@ -68,9 +68,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ owncast_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -78,10 +78,10 @@
become: true
- name: Compose owncast
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ owncast_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- owncast

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -32,9 +32,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ penpot_install_location }}"
become: true
@ -54,19 +54,19 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ penpot_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- penpot
become: true
- name: Compose penpot
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ penpot_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -21,9 +21,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ static_websites_install_location }}"
become: true
@ -34,9 +34,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ static_websites_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
when:
- static_websites | length > 0
@ -46,10 +46,10 @@
become: true
- name: Compose static websites
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ static_websites_install_location }}"
pull: true
pull: always
remove_orphans: true
become: true
when:

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
selevel: "{{ teamspeak_selinux_level }}"
state: present
@ -31,9 +31,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ teamspeak_install_location }}"
tags:
@ -56,9 +56,9 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ teamspeak_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
@ -66,10 +66,10 @@
become: true
- name: Compose teamspeak
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ teamspeak_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker

View file

@ -18,7 +18,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
- name: Restart telegraf
community.docker.docker_compose:
community.docker.docker_compose_v2:
project_src: "{{ telegraf_install_location }}"
restarted: true
state: restarted
become: true

View file

@ -19,7 +19,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -30,9 +30,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ telegraf_install_location }}"
become: true
@ -40,7 +40,7 @@
- name: Create config directory
ansible.builtin.file:
path: "{{ item }}"
mode: '0700'
mode: "0700"
owner: "{{ telegraf_config_uid }}"
group: "{{ telegraf_config_gid }}"
state: directory
@ -53,9 +53,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ telegraf_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
become: true
@ -63,16 +63,16 @@
ansible.builtin.template:
src: "telegraf.conf"
dest: "{{ telegraf_config_location }}/telegraf.conf"
mode: '0600'
mode: "0600"
owner: "{{ telegraf_config_uid }}"
group: "{{ telegraf_config_gid }}"
notify: "Restart telegraf"
become: true
- name: Compose telegraf
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ telegraf_install_location }}"
pull: true
pull: always
remove_orphans: true
become: true

View file

@ -21,7 +21,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
selevel: "{{ traefik_selinux_level }}"
state: present
@ -36,9 +36,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ traefik_install_location }}"
become: true
@ -47,9 +47,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
setype: "container_file_t"
selevel: "{{ traefik_selinux_level }}"
with_items:
@ -107,9 +107,9 @@
ansible.builtin.template:
src: dynamic_conf.yml
dest: "{{ traefik_config_location }}/dynamic_conf.yml"
owner: 'root'
group: 'root'
mode: '0600'
owner: "root"
group: "root"
mode: "0600"
setype: "container_file_t"
selevel: "{{ traefik_selinux_level }}"
become: true
@ -120,19 +120,19 @@
ansible.builtin.template:
src: docker-compose.yml
dest: "{{ traefik_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- docker
become: true
- name: Compose traefik
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ traefik_install_location }}"
pull: true
pull: always
remove_orphans: true
become: true

View file

@ -18,9 +18,9 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
- name: Restart vikunja-api
community.docker.docker_compose:
community.docker.docker_compose_v2:
services:
- api
project_src: "{{ vikunja_install_location }}"
restarted: true
state: restarted
become: true

View file

@ -22,7 +22,7 @@
- name: Update default SELinux contexts
community.general.sefcontext:
target: '{{ item }}(/.*)?'
target: "{{ item }}(/.*)?"
setype: "container_file_t"
state: present
with_items:
@ -36,9 +36,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: 'root'
group: 'root'
mode: "0700"
owner: "root"
group: "root"
with_items:
- "{{ vikunja_install_location }}"
become: true
@ -56,9 +56,9 @@
ansible.builtin.file:
path: "{{ item }}"
state: directory
mode: '0700'
owner: '1000'
group: '1000'
mode: "0700"
owner: "1000"
group: "1000"
setype: "container_file_t"
selevel: "{{ vikunja_selinux_level }}"
with_items:
@ -69,9 +69,9 @@
ansible.builtin.template:
src: "docker-compose.yml"
dest: "{{ vikunja_install_location }}/docker-compose.yml"
mode: '0600'
owner: 'root'
group: 'root'
mode: "0600"
owner: "root"
group: "root"
validate: docker-compose -f %s config -q
tags:
- vikunja
@ -81,19 +81,19 @@
ansible.builtin.template:
src: "config.yml"
dest: "{{ vikunja_install_location }}/config.yml"
owner: '1000'
group: '1000'
mode: '0600'
owner: "1000"
group: "1000"
mode: "0600"
setype: "container_file_t"
selevel: "{{ vikunja_selinux_level }}"
notify: "Restart vikunja-api"
become: true
- name: Compose vikunja
community.docker.docker_compose:
community.docker.docker_compose_v2:
state: present
project_src: "{{ vikunja_install_location }}"
pull: true
pull: always
remove_orphans: true
tags:
- docker