Added ntfy router to ansible scripts

This commit is contained in:
Ashish D'Souza 2023-11-19 05:12:40 -06:00
parent 7b51846e1b
commit 8a76bddbf1
2 changed files with 26 additions and 0 deletions

View File

@ -39,6 +39,30 @@
path: '{{docker_build_dir.path}}'
state: absent
- name: Create temporary Docker build directory for broadcast-ntfy-router
ansible.builtin.tempfile:
state: directory
register: docker_build_dir
- name: Copy Docker build directory
ansible.builtin.copy:
src: ntfy_router/
dest: '{{docker_build_dir.path}}'
mode: preserve
- name: Build broadcast-ntfy-router Docker image
ansible.builtin.docker_image:
build:
path: '{{docker_build_dir.path}}'
name: broadcast-ntfy-router
tag: latest
source: build
force_source: true
state: present
- name: Remove temporary Docker build directory
become: true
ansible.builtin.file:
path: '{{docker_build_dir.path}}'
state: absent
- name: Read homelab config
ansible.builtin.slurp:
src: '{{ansible_user_dir}}/.homelab.json'

View File

@ -12,6 +12,8 @@
mode: preserve
- name: Docker Compose down Broadcast
environment:
SERVER_IP: '{{ansible_default_ipv4.address}}'
community.docker.docker_compose:
project_name: broadcast
project_src: '{{docker_compose_dir.path}}'