diff --git a/scripts/deluge/Caddyfile.templ b/scripts/deluge/Caddyfile.templ deleted file mode 100644 index 7da8288..0000000 --- a/scripts/deluge/Caddyfile.templ +++ /dev/null @@ -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 -} diff --git a/scripts/deluge/deluge.Caddyfile b/scripts/deluge/deluge.Caddyfile new file mode 100644 index 0000000..c0d333b --- /dev/null +++ b/scripts/deluge/deluge.Caddyfile @@ -0,0 +1,4 @@ +https://torrent.{$DOMAIN} { + import internal_only + reverse_proxy http://localhost:8085 +} diff --git a/scripts/deluge/script.sh b/scripts/deluge/script.sh index 39d5dbf..56d89f1 100644 --- a/scripts/deluge/script.sh +++ b/scripts/deluge/script.sh @@ -3,7 +3,7 @@ set -euo pipefail source "$HL_LIB" -_assert_vars HL_TIMEZONE HL_DOMAIN; +_assert_vars HL_TIMEZONE; _ch_001-make_dirs() { mkdir -p ~/deluge /data/deluge; @@ -14,8 +14,7 @@ _ch_002-copy_compose() { } _ch_003-update_caddy() { - cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/deluge.Caddyfile; - chmod a+r /etc/caddy/conf.d/deluge.Caddyfile; + cp deluge.Caddyfile /etc/caddy/conf.d; sudo systemctl reload caddy.service; } diff --git a/scripts/jellyfin/Caddyfile.templ b/scripts/jellyfin/Caddyfile.templ deleted file mode 100644 index b098834..0000000 --- a/scripts/jellyfin/Caddyfile.templ +++ /dev/null @@ -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 -} - diff --git a/scripts/jellyfin/jellyfin.Caddyfile b/scripts/jellyfin/jellyfin.Caddyfile new file mode 100644 index 0000000..3d10703 --- /dev/null +++ b/scripts/jellyfin/jellyfin.Caddyfile @@ -0,0 +1,5 @@ +https://film.{$DOMAIN} { + import internal_only + reverse_proxy http://localhost:8096 +} + diff --git a/scripts/jellyfin/script.sh b/scripts/jellyfin/script.sh index d17b152..f191d1b 100644 --- a/scripts/jellyfin/script.sh +++ b/scripts/jellyfin/script.sh @@ -14,8 +14,7 @@ _ch_002-copy_compose() { } _ch_003-update_caddy() { - cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/jellyfin.Caddyfile; - chmod a+r /etc/caddy/conf.d/jellyfin.Caddyfile; + cp jellyfin.Caddyfile /etc/caddy/conf.d; sudo systemctl reload caddy.service; } diff --git a/scripts/nextcloud/Caddyfile.templ b/scripts/nextcloud/Caddyfile.templ deleted file mode 100644 index 1e87c8b..0000000 --- a/scripts/nextcloud/Caddyfile.templ +++ /dev/null @@ -1,7 +0,0 @@ -https://cloud.$domain { - reverse_proxy https://localhost:4987 { - transport http { - tls_insecure_skip_verify - } - } -} diff --git a/scripts/nextcloud/nextcloud.Caddyfile b/scripts/nextcloud/nextcloud.Caddyfile new file mode 100644 index 0000000..500fc4f --- /dev/null +++ b/scripts/nextcloud/nextcloud.Caddyfile @@ -0,0 +1,7 @@ +https://cloud.{$DOMAIN} { + reverse_proxy https://localhost:4987 { + transport http { + tls_insecure_skip_verify + } + } +} diff --git a/scripts/nextcloud/script.sh b/scripts/nextcloud/script.sh index 639cf46..53eb355 100644 --- a/scripts/nextcloud/script.sh +++ b/scripts/nextcloud/script.sh @@ -3,7 +3,7 @@ set -euo pipefail source "$HL_LIB" -_assert_vars HL_TIMEZONE HL_DOMAIN; +_assert_vars HL_TIMEZONE; _ch_001-make_dirs() { mkdir -p ~/nextcloud /data/nextcloud; @@ -14,8 +14,7 @@ _ch_002-copy_compose() { } _ch_003-update_caddy() { - cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/nextcloud.Caddyfile; - chmod a+r /etc/caddy/conf.d/nextcloud.Caddyfile; + cp nextcloud.Caddyfile /etc/caddy/conf.d; sudo systemctl reload caddy.service; } @@ -24,5 +23,4 @@ _ch_004-run_service() { docker-compose up -d; } - _run_checkpoints diff --git a/scripts/paperlessngx/Caddyfile.templ b/scripts/paperlessngx/Caddyfile.templ deleted file mode 100644 index 4a86c29..0000000 --- a/scripts/paperlessngx/Caddyfile.templ +++ /dev/null @@ -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 -} diff --git a/scripts/paperlessngx/paperlessngx.Caddyfile b/scripts/paperlessngx/paperlessngx.Caddyfile new file mode 100644 index 0000000..160f335 --- /dev/null +++ b/scripts/paperlessngx/paperlessngx.Caddyfile @@ -0,0 +1,4 @@ +https://paperless.{$DOMAIN} { + import internal_only + reverse_proxy http://localhost:8097 +} diff --git a/scripts/paperlessngx/script.sh b/scripts/paperlessngx/script.sh index 9821fff..563f439 100644 --- a/scripts/paperlessngx/script.sh +++ b/scripts/paperlessngx/script.sh @@ -16,8 +16,7 @@ _ch_002-copy_compose() { } _ch_003-update_caddy() { - cp $(_fill Caddyfile.templ) /etc/caddy/conf.d/paperlessngx.Caddyfile; - chmod a+r /etc/caddy/conf.d/paperlessngx.Caddyfile; + cp paperlessngx.Caddyfile /etc/caddy/conf.d; sudo systemctl reload caddy.service; }