Compare commits

...

2 Commits

Author SHA1 Message Date
1c75f8b93f
meta: add tags to collection 2024-10-05 10:32:50 +02:00
29ffe7f8fa
feat(hydrogen): add deployment method podman 2024-10-05 10:31:48 +02:00
4 changed files with 41 additions and 0 deletions

View File

@ -10,3 +10,10 @@ build_ignore:
- '*.tar.gz'
repository: https://git.finally.coffee/finallycoffee/matrix
issues: https://codeberg.org/finallycoffee/ansible-collection-matrix/issues
tags:
- matrix
- synapse
- homeserver
- element
- hydrogen
- cinny

View File

@ -9,3 +9,4 @@ galaxy_info:
- matrix
- matrix-client
- docker
- podman

View File

@ -0,0 +1,32 @@
---
- name: Ensure container image '{{ hydrogen_container_image }}' is {{ hydrogen_state }} on host
containers.podman.podman_image:
name: "{{ hydrogen_container_image }}"
state: "{{ hydrogen_state }}"
pull: "{{ hydrogen_container_image_source == 'pull' }}"
force: "{{ hydrogen_container_image_force_source }}"
register: hydrogen_container_image_info
until: hydrogen_container_image_info is success
retries: 5
delay: 3
- name: Ensure hydrogen container '{{ hydrogen_container_name }}' is {{ hydrogen_container_state }}
containers.podman.podman_container:
name: "{{ hydrogen_container_name }}"
image: "{{ hydrogen_container_image }}"
env: "{{ hydrogen_container_env | default(omit, true) }}"
user: "{{ hydrogen_container_user }}"
ports: "{{ hydrogen_container_ports | default(omit, true) }}"
labels: "{{ hydrogen_container_labels | default(omit, true) }}"
ulimits: "{{ hydrogen_container_ulimits | default(omit, true) }}"
volumes: "{{ hydrogen_container_volumes }}"
network: "{{ hydrogen_container_networks | default(omit, true) }}"
purge_networks: >-2
{{ hydrogen_container_purge_networks | default(omit, true) }}
dns_servers: >-2
{{ hydrogen_container_dns_servers | default(omit, true) }}
etc_hosts: >-2
{{ hydrogen_container_etc_hosts | default(omit, true) }}
restart_policy: >-2
{{ hydrogen_container_restart_policy | default(omit, true) }}
state: "{{ hydrogen_container_state }}"

View File

@ -4,3 +4,4 @@ hydrogen_states:
- absent
hydrogen_deployment_methods:
- docker
- podman