-
Notifications
You must be signed in to change notification settings - Fork 5
/
overseerr.yml
178 lines (160 loc) · 5.93 KB
/
overseerr.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
---
- hosts: homelab
vars:
application: overseerr
docker_network: "{{ networks.pub }}"
handlers:
- name: Restart
community.docker.docker_container:
name: "{{ application }}"
restart: true
comparisons:
'*': ignore
tasks:
- name: Create config folder
ansible.builtin.file:
path: "{{ config_directory }}"
state: directory
owner: "{{ common_user }}"
group: "{{ common_group }}"
mode: "0771"
- name: Create container
ansible.builtin.include_role:
name: docker_container
vars:
image: sctx/overseerr:1.33.2
env:
TZ: "{{ common_timezone }}"
volumes:
- "{{ config_directory }}:/app/config"
user: "{{ common_user_id }}:{{ common_group_id }}"
traefik:
- port: 5055
homepage:
group: Media
weight: 100
description: "Request and discover media"
widget:
key: !vault |
$ANSIBLE_VAULT;1.1;AES256
36376362623361376437353264353732313638333038353063646463613839633234633330633839
3433623337353638393133323932653036393432343564330a366163393838356239343162643238
39326435316262663964356338393261343330353034623465663534353238396639613638636665
6430616530326464300a626662636364663561313762636338373638373236386633663464343332
38313737313666373265376362383033643764636463343238623362656563626238323265636334
39343034366338663563656363383965663063373036623132373061613734643330666666363335
66653634303032666239393938643461653835633261633138656639316335306531626133353865
37376238643233646436
fields: '["pending", "processing"]'
blackbox:
path: /api/v1/status
- name: Wait for config
ansible.builtin.wait_for:
path: "{{ config_directory }}/settings.json"
- name: Initialise Sonarr array
block:
- name: Check Sonarr array
json_patch:
src: "{{ config_directory }}/settings.json"
operations:
- op: test
path: sonarr/0/id
value: 0
- op: test
path: sonarr/1/id
value: 1
register: _overseer_sonarr_exists
- name: Add Sonarr array
json_patch:
src: "{{ config_directory }}/settings.json"
operations:
- op: add
path: sonarr/-
value:
id: 0
- op: add
path: sonarr/-
value:
id: 1
when: not _overseer_sonarr_exists.tested
- name: Initialise Radarr array
block:
- name: Check Radarr array
json_patch:
src: "{{ config_directory }}/settings.json"
operations:
- op: test
path: radarr/0/id
value: 0
register: _overseer_radarr_exists
- name: Add Radarr array
json_patch:
src: "{{ config_directory }}/settings.json"
operations:
- op: add
path: radarr/-
value:
id: 0
when: not _overseer_radarr_exists.tested
- name: Configure
json_patch: # noqa fqcn[action]
src: "{{ config_directory }}/settings.json"
pretty: true
operations:
- op: add
path: "{{ item.key }}"
value: "{{ item.value }}"
loop: "{{ _overseerr_configuration | dict2items }}"
notify: Restart
vars:
_overseerr_configuration:
main/applicationUrl: "https://{{ application }}.{{ common_tld }}"
main/cacheImages: true
main/localLogin: false
main/trustProxy: true
plex/name: plex
plex/ip: plex.{{ networks.pub.name }}
plex/webAppUrl: "https://plex.{{ common_tld }}"
tautulli/hostname: tautulli.{{ networks.pub.name }}
tautulli/port: 8181
tautulli/useSsl: false
tautulli/apiKey: "{{ tautulli_api_key }}"
tautulli/externalUrl: "https://tautulli.{{ common_tld }}"
radarr/0/isDefault: true
radarr/0/name: Radarr
radarr/0/hostname: "radarr.{{ networks.pub.name }}"
radarr/0/port: 7878
radarr/0/useSsl: false
radarr/0/apiKey: "{{ radarr_api_key }}"
radarr/0/externalUrl: "https://radarr.{{ common_tld }}"
radarr/0/syncEnabled: true
radarr/0/preventSearch: false
sonarr/0/isDefault: true
sonarr/0/name: Sonarr
sonarr/0/hostname: "sonarr.{{ networks.pub.name }}"
sonarr/0/port: 8989
sonarr/0/useSsl: false
sonarr/0/apiKey: "{{ sonarr_api_key }}"
sonarr/0/activeProfileName: "1080p"
sonarr/0/activeDirectory: "{{ common_mounted_directory_tv }}"
sonarr/0/enableSeasonFolders: true
sonarr/0/externalUrl: "https://sonarr.{{ common_tld }}"
sonarr/0/syncEnabled: true
sonarr/0/preventSearch: false
sonarr/1/isDefault: false
sonarr/1/name: Sonarr Anime
sonarr/1/hostname: "sonarr-anime.{{ networks.pub.name }}"
sonarr/1/port: 8989
sonarr/1/useSsl: false
sonarr/1/apiKey: "{{ sonarr_api_key }}"
sonarr/1/activeProfileName: "Anime"
sonarr/1/activeDirectory: "{{ common_mounted_directory_tv }}"
sonarr/1/activeAnimeProfileName: "Anime"
sonarr/1/activeAnimeDirectory: "{{ common_mounted_directory_tv }}"
sonarr/1/enableSeasonFolders: true
sonarr/1/externalUrl: "https://sonarr-anime.{{ common_tld }}"
sonarr/1/syncEnabled: true
sonarr/1/preventSearch: false
- name: Send message
ansible.builtin.debug:
msg: More configuration may be required via the UI to set paths and quality profiles