2025-07-08 15:07:56 -04:00

35 lines
861 B
YAML

# - name: Create DB
# ansible.builtin.include_role:
# name: app/database
# vars:
# app_name: "booklore"
- name: Create data folder
ansible.builtin.include_role:
name: docker/container-data
vars:
dir_name: "komga"
- name: Create necessary subfolders
ansible.builtin.file:
dest: "{{ container_data_base_path }}/komga/{{ item }}"
state: directory
mode: '0777'
loop:
- data
- "data/books"
- config
- name: Deploy container
community.docker.docker_container:
name: komga-ebook-library
pull: true
state: started
image: gotson/komga
volumes:
- "{{ container_data_base_path }}/komga/config:/config"
- "{{ container_data_base_path }}/komga/data:/data"
- /etc/timezone:/etc/timezone
ports:
- "{{ port }}:25600"
user: "1000:1000"
restart_policy: unless-stopped