61 lines
1.8 KiB
YAML
61 lines
1.8 KiB
YAML
---
|
|
- name: Setup Caddy
|
|
hosts: privfrontends,core
|
|
tasks:
|
|
- name: Copy Caddyfile
|
|
ansible.builtin.template:
|
|
src: ./templates/Caddyfile.j2
|
|
dest: /etc/caddy/Caddyfile
|
|
mode: preserve
|
|
tags: caddy-non-update
|
|
- name: Copy per-server caddy extras
|
|
ansible.builtin.copy:
|
|
src: "./templates/{{ inventory_hostname }}/"
|
|
dest: /etc/caddy/
|
|
directory_mode: true
|
|
mode: preserve
|
|
tags: caddy-non-update
|
|
- name: Reload Caddy
|
|
ansible.builtin.service:
|
|
name: caddy
|
|
enabled: true
|
|
state: reloaded
|
|
tags: caddy-non-update
|
|
- name: Setup docker compose for privacy frontends
|
|
hosts: privfrontends
|
|
vars:
|
|
docker_services:
|
|
- librarian
|
|
- libreddit
|
|
- nitter
|
|
- teddit
|
|
- watchtower
|
|
tasks:
|
|
# community.docker does not support compose 2.0 right now.
|
|
# https://github.com/ansible-collections/community.docker/issues/216
|
|
- name: Update docker compose files and restart those with changes
|
|
ansible.builtin.include_tasks: docker-tasks.yaml
|
|
with_items: "{{ docker_services }}"
|
|
tags: docker,pizza
|
|
- name: Setup docker compose for privacy frontends (soleil+normal)
|
|
hosts: in,us,docker
|
|
vars:
|
|
non_pizza_docker_services:
|
|
- anonymousoverflow
|
|
- breezewiki
|
|
- gothub
|
|
- gothub-dev
|
|
- searxng
|
|
- hyperpipe
|
|
- rimgo
|
|
- safetwitch
|
|
- scribe
|
|
- simplytranslate
|
|
tasks:
|
|
# community.docker does not support compose 2.0 right now.
|
|
# https://github.com/ansible-collections/community.docker/issues/216
|
|
- name: Update docker compose files and restart those with changes (Privacy Frontends but without Pizza1)
|
|
ansible.builtin.include_tasks: docker-tasks.yaml
|
|
with_items: "{{ non_pizza_docker_services }}"
|
|
tags: docker,soleil
|