ansible-nas/roles/calibre/tasks/main.yml
HitLuca 59e47c4ebf 🏗️ converted remaining tasks to proper roles, moving vars definitions into proper role subfolder.
🐛 added missing entries in nas.yml (?!?)
♻️ reordered entries in nas.yml in alphabetical order. Renamed vd variables to virtual_desktop for ease of understanding
2022-07-27 10:41:17 +02:00

32 lines
1.1 KiB
YAML

---
- name: Create Calibre-web Directories
file:
path: "{{ item }}"
state: directory
with_items:
- "{{ calibre_data_directory }}/config"
- name: Calibre-web Docker Container
docker_container:
name: calibre
image: linuxserver/calibre-web:latest
pull: true
volumes:
- "{{ calibre_data_directory }}/config:/config"
- "{{ calibre_books_root }}:/books"
env:
TZ: "{{ ansible_nas_timezone }}"
PUID: "{{ calibre_user_id }}"
PGID: "{{ calibre_group_id }}"
DOCKER_MODS: "{{ calibre_ebook_conversion }}"
ports:
- "{{ calibre_port }}:8083"
restart_policy: unless-stopped
memory: "{{ calibre_memory }}"
labels:
traefik.enable: "{{ calibre_available_externally }}"
traefik.http.routers.calibre.rule: "Host(`calibre.{{ ansible_nas_domain }}`)"
traefik.http.routers.calibre.tls.certresolver: "letsencrypt"
traefik.http.routers.calibre.tls.domains[0].main: "{{ ansible_nas_domain }}"
traefik.http.routers.calibre.tls.domains[0].sans: "*.{{ ansible_nas_domain }}"
traefik.http.services.calibre.loadbalancer.server.port: "8083"