update Caddyfiles to use ENV var and snippets
This commit is contained in:
parent
b11315c19d
commit
d657960f62
12 changed files with 26 additions and 34 deletions
|
@ -1,5 +0,0 @@
|
||||||
https://torrent.$domain {
|
|
||||||
@blocked not remote_ip 10.0.0.0/24 10.0.89.0/24
|
|
||||||
respond @blocked "Internal use only" 403
|
|
||||||
reverse_proxy http://localhost:8085
|
|
||||||
}
|
|
4
scripts/deluge/deluge.Caddyfile
Normal file
4
scripts/deluge/deluge.Caddyfile
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
https://torrent.{$DOMAIN} {
|
||||||
|
import internal_only
|
||||||
|
reverse_proxy http://localhost:8085
|
||||||
|
}
|
|
@ -3,7 +3,7 @@ set -euo pipefail
|
||||||
|
|
||||||
source "$HL_LIB"
|
source "$HL_LIB"
|
||||||
|
|
||||||
_assert_vars HL_TIMEZONE HL_DOMAIN;
|
_assert_vars HL_TIMEZONE;
|
||||||
|
|
||||||
_ch_001-make_dirs() {
|
_ch_001-make_dirs() {
|
||||||
mkdir -p ~/deluge /data/deluge;
|
mkdir -p ~/deluge /data/deluge;
|
||||||
|
@ -14,8 +14,7 @@ _ch_002-copy_compose() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_ch_003-update_caddy() {
|
_ch_003-update_caddy() {
|
||||||
cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/deluge.Caddyfile;
|
cp deluge.Caddyfile /etc/caddy/conf.d;
|
||||||
chmod a+r /etc/caddy/conf.d/deluge.Caddyfile;
|
|
||||||
sudo systemctl reload caddy.service;
|
sudo systemctl reload caddy.service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,6 +0,0 @@
|
||||||
https://film.$domain {
|
|
||||||
@blocked not remote_ip 10.0.0.0/24 10.0.89.0/24
|
|
||||||
respond @blocked "Internal use only" 403
|
|
||||||
reverse_proxy http://localhost:8096
|
|
||||||
}
|
|
||||||
|
|
5
scripts/jellyfin/jellyfin.Caddyfile
Normal file
5
scripts/jellyfin/jellyfin.Caddyfile
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
https://film.{$DOMAIN} {
|
||||||
|
import internal_only
|
||||||
|
reverse_proxy http://localhost:8096
|
||||||
|
}
|
||||||
|
|
|
@ -14,8 +14,7 @@ _ch_002-copy_compose() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_ch_003-update_caddy() {
|
_ch_003-update_caddy() {
|
||||||
cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/jellyfin.Caddyfile;
|
cp jellyfin.Caddyfile /etc/caddy/conf.d;
|
||||||
chmod a+r /etc/caddy/conf.d/jellyfin.Caddyfile;
|
|
||||||
sudo systemctl reload caddy.service;
|
sudo systemctl reload caddy.service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,7 +0,0 @@
|
||||||
https://cloud.$domain {
|
|
||||||
reverse_proxy https://localhost:4987 {
|
|
||||||
transport http {
|
|
||||||
tls_insecure_skip_verify
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
7
scripts/nextcloud/nextcloud.Caddyfile
Normal file
7
scripts/nextcloud/nextcloud.Caddyfile
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
https://cloud.{$DOMAIN} {
|
||||||
|
reverse_proxy https://localhost:4987 {
|
||||||
|
transport http {
|
||||||
|
tls_insecure_skip_verify
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
|
@ -3,7 +3,7 @@ set -euo pipefail
|
||||||
|
|
||||||
source "$HL_LIB"
|
source "$HL_LIB"
|
||||||
|
|
||||||
_assert_vars HL_TIMEZONE HL_DOMAIN;
|
_assert_vars HL_TIMEZONE;
|
||||||
|
|
||||||
_ch_001-make_dirs() {
|
_ch_001-make_dirs() {
|
||||||
mkdir -p ~/nextcloud /data/nextcloud;
|
mkdir -p ~/nextcloud /data/nextcloud;
|
||||||
|
@ -14,8 +14,7 @@ _ch_002-copy_compose() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_ch_003-update_caddy() {
|
_ch_003-update_caddy() {
|
||||||
cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/nextcloud.Caddyfile;
|
cp nextcloud.Caddyfile /etc/caddy/conf.d;
|
||||||
chmod a+r /etc/caddy/conf.d/nextcloud.Caddyfile;
|
|
||||||
sudo systemctl reload caddy.service;
|
sudo systemctl reload caddy.service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,5 +23,4 @@ _ch_004-run_service() {
|
||||||
docker-compose up -d;
|
docker-compose up -d;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
_run_checkpoints
|
_run_checkpoints
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
https://paperless.$domain {
|
|
||||||
@blocked not remote_ip 10.0.0.0/24 10.0.89.0/24
|
|
||||||
respond @blocked "Internal use only" 403
|
|
||||||
reverse_proxy http://localhost:8097
|
|
||||||
}
|
|
4
scripts/paperlessngx/paperlessngx.Caddyfile
Normal file
4
scripts/paperlessngx/paperlessngx.Caddyfile
Normal file
|
@ -0,0 +1,4 @@
|
||||||
|
https://paperless.{$DOMAIN} {
|
||||||
|
import internal_only
|
||||||
|
reverse_proxy http://localhost:8097
|
||||||
|
}
|
|
@ -16,8 +16,7 @@ _ch_002-copy_compose() {
|
||||||
}
|
}
|
||||||
|
|
||||||
_ch_003-update_caddy() {
|
_ch_003-update_caddy() {
|
||||||
cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/paperlessngx.Caddyfile;
|
cp paperlessngx.Caddyfile /etc/caddy/conf.d;
|
||||||
chmod a+r /etc/caddy/conf.d/paperlessngx.Caddyfile;
|
|
||||||
sudo systemctl reload caddy.service;
|
sudo systemctl reload caddy.service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue