ansible-nas/roles/freshrss/tasks/main.yml

33 lines
1.2 KiB
YAML
Raw Normal View History

---
- name: Create FreshRSS Directories
file:
path: "{{ item }}"
state: directory
# mode: 0755
with_items:
- "{{ freshrss_data_directory }}/data"
- "{{ freshrss_extensions_directory }}/extensions"
- name: FreshRSS Docker Container
docker_container:
name: freshrss
image: freshrss/freshrss
pull: true
volumes:
- "{{ freshrss_data_directory }}/data:/var/www/FreshRSS/data:rw"
- "{{ freshrss_extensions_directory }}/extensions:/var/www/FreshRSS/extensions:rw"
ports:
- "{{ freshrss_port }}:80"
env:
TZ: "{{ ansible_nas_timezone }}"
CRON_MIN: "1,31"
restart_policy: unless-stopped
memory: "{{ freshrss_memory }}"
labels:
traefik.enable: "{{ freshrss_available_externally | string }}"
traefik.http.routers.freshrss.rule: "Host(`{{ freshrss_hostname }}.{{ ansible_nas_domain }}`)"
traefik.http.routers.freshrss.tls.certresolver: "letsencrypt"
traefik.http.routers.freshrss.tls.domains[0].main: "{{ ansible_nas_domain }}"
traefik.http.routers.freshrss.tls.domains[0].sans: "*.{{ ansible_nas_domain }}"
traefik.http.services.freshrss.loadbalancer.server.port: "80"