Deploy uptime-kuma

This commit is contained in:
Jake Howard
2024-04-21 18:11:39 +01:00
parent 7564911da3
commit c472411801
9 changed files with 70 additions and 0 deletions

View File

@ -0,0 +1,18 @@
version: "2.3"
services:
uptime-kuma:
image: louislam/uptime-kuma:1.23.11-alpine
environment:
- TZ={{ timezone }}
- PUID={{ docker_user.id }}
- PGID={{ docker_user.id }}
ports:
- "{{ pve_hosts.forrest.ip }}:3001:3001"
volumes:
- "{{ app_data_dir }}/uptime-kuma:/app/data"
restart: unless-stopped
networks:
default:
enable_ipv6: true

View File

@ -0,0 +1,4 @@
- name: restart uptime-kuma
shell:
chdir: /opt/uptime-kuma
cmd: "{{ docker_update_command }}"

View File

@ -0,0 +1,17 @@
- name: Create install directory
file:
path: /opt/uptime-kuma
state: directory
owner: "{{ docker_user.name }}"
mode: "{{ docker_compose_directory_mask }}"
become: true
- name: Install compose file
template:
src: files/docker-compose.yml
dest: /opt/uptime-kuma/docker-compose.yml
mode: "{{ docker_compose_file_mask }}"
owner: "{{ docker_user.name }}"
validate: docker-compose -f %s config
notify: restart uptime-kuma
become: true