mirror of
https://github.com/davestephens/ansible-nas
synced 2025-01-26 02:05:05 +00:00
mv jellyfin to roles
This commit is contained in:
parent
871bf8f3b1
commit
fd49efaa46
4 changed files with 43 additions and 31 deletions
|
@ -26,7 +26,6 @@ tautulli_enabled: false
|
|||
get_iplayer_enabled: false
|
||||
jackett_enabled: false
|
||||
minidlna_enabled: false
|
||||
jellyfin_enabled: false
|
||||
|
||||
|
||||
youtubedlmaterial_enabled: false
|
||||
|
@ -525,30 +524,6 @@ openhab_data_directory: "{{ docker_home }}/openhab"
|
|||
openhab_port_http: "7777"
|
||||
openhab_port_https: "7778"
|
||||
|
||||
###
|
||||
### Jellyfin
|
||||
###
|
||||
# If you're paranoid, set permissions to "ro" so jellyfin won't ever be able to
|
||||
# delete your files
|
||||
jellyfin_available_externally: "false"
|
||||
jellyfin_config_directory: "{{ docker_home }}/jellyfin/config"
|
||||
jellyfin_movies_directory: "{{ movies_root }}"
|
||||
jellyfin_movies_permissions: "rw"
|
||||
jellyfin_music_directory: "{{ music_root }}"
|
||||
jellyfin_music_permissions: "rw"
|
||||
jellyfin_photos_directory: "{{ photos_root }}"
|
||||
jellyfin_photos_permissions: "rw"
|
||||
jellyfin_tv_directory: "{{ tv_root }}"
|
||||
jellyfin_tv_permissions: "rw"
|
||||
jellyfin_books_directory: "{{ books_root }}"
|
||||
jellyfin_books_permissions: "rw"
|
||||
jellyfin_audiobooks_directory: "{{ audiobooks_root }}"
|
||||
jellyfin_audiobooks_permissions: "rw"
|
||||
jellyfin_user_id: "0"
|
||||
jellyfin_group_id: "0"
|
||||
jellyfin_port_http: "8896"
|
||||
jellyfin_port_https: "8928"
|
||||
|
||||
###
|
||||
### Ubooquity
|
||||
###
|
||||
|
|
9
nas.yml
9
nas.yml
|
@ -98,6 +98,11 @@
|
|||
- homeassistant
|
||||
when: (homeassistant_enabled | default(False))
|
||||
|
||||
- role: jellyfin
|
||||
tags:
|
||||
- jellyfin
|
||||
when: (jellyfin_enabled | default(False))
|
||||
|
||||
- role: lidarr
|
||||
tags:
|
||||
- lidarr
|
||||
|
@ -281,10 +286,6 @@
|
|||
when: (openhab_enabled | default(False))
|
||||
tags: openhab
|
||||
|
||||
- import_tasks: tasks/jellyfin.yml
|
||||
when: (jellyfin_enabled | default(False))
|
||||
tags: jellyfin
|
||||
|
||||
- import_tasks: tasks/cloudcmd.yml
|
||||
when: (cloudcmd_enabled | default(False))
|
||||
tags: cloudcmd
|
||||
|
|
33
roles/jellyfin/defaults/main.yml
Normal file
33
roles/jellyfin/defaults/main.yml
Normal file
|
@ -0,0 +1,33 @@
|
|||
---
|
||||
# enable or disable the application
|
||||
jellyfin_enabled: false
|
||||
jellyfin_available_externally: "false"
|
||||
|
||||
# directories
|
||||
jellyfin_config_directory: "{{ docker_home }}/jellyfin/config"
|
||||
jellyfin_movies_directory: "{{ movies_root }}"
|
||||
jellyfin_music_directory: "{{ music_root }}"
|
||||
jellyfin_photos_directory: "{{ photos_root }}"
|
||||
jellyfin_tv_directory: "{{ tv_root }}"
|
||||
jellyfin_books_directory: "{{ books_root }}"
|
||||
jellyfin_audiobooks_directory: "{{ audiobooks_root }}"
|
||||
|
||||
# permissions
|
||||
jellyfin_movies_permissions: "rw"
|
||||
jellyfin_music_permissions: "rw"
|
||||
jellyfin_photos_permissions: "rw"
|
||||
jellyfin_tv_permissions: "rw"
|
||||
jellyfin_books_permissions: "rw"
|
||||
jellyfin_audiobooks_permissions: "rw"
|
||||
|
||||
# uid / gid
|
||||
jellyfin_user_id: "0"
|
||||
jellyfin_group_id: "0"
|
||||
|
||||
# network
|
||||
jellyfin_hostname: "jellyfin"
|
||||
jellyfin_port_http: "8896"
|
||||
jellyfin_port_https: "8928"
|
||||
|
||||
# specs
|
||||
jellyfin_memory: "1g"
|
|
@ -1,7 +1,9 @@
|
|||
---
|
||||
- name: Create Jellyfin Directories
|
||||
file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
# mode: 0755
|
||||
with_items:
|
||||
- "{{ jellyfin_config_directory }}"
|
||||
|
||||
|
@ -18,6 +20,7 @@
|
|||
- "{{ jellyfin_tv_directory }}:/tv:{{ jellyfin_tv_permissions }}"
|
||||
- "{{ jellyfin_books_directory }}:/books:{{ jellyfin_tv_permissions }}"
|
||||
- "{{ jellyfin_audiobooks_directory }}:/audiobooks:{{ jellyfin_tv_permissions }}"
|
||||
network_mode: "bridge"
|
||||
ports:
|
||||
- "{{ jellyfin_port_http }}:8096"
|
||||
- "{{ jellyfin_port_https }}:8920"
|
||||
|
@ -26,10 +29,10 @@
|
|||
PUID: "{{ jellyfin_user_id }}"
|
||||
PGID: "{{ jellyfin_group_id }}"
|
||||
restart_policy: unless-stopped
|
||||
memory: 1g
|
||||
memory: "{{ jellyfin_memory }}"
|
||||
labels:
|
||||
traefik.enable: "{{ jellyfin_available_externally }}"
|
||||
traefik.http.routers.jellyfin.rule: "Host(`jellyfin.{{ ansible_nas_domain }}`)"
|
||||
traefik.http.routers.jellyfin.rule: "Host(`{{ jellyfin_hostname }}.{{ ansible_nas_domain }}`)"
|
||||
traefik.http.routers.jellyfin.tls.certresolver: "letsencrypt"
|
||||
traefik.http.routers.jellyfin.tls.domains[0].main: "{{ ansible_nas_domain }}"
|
||||
traefik.http.routers.jellyfin.tls.domains[0].sans: "*.{{ ansible_nas_domain }}"
|
Loading…
Reference in a new issue