mirror of
https://github.com/gilbN/theme.park.git
synced 2024-08-18 07:59:37 +02:00
Update all mods to support s6-v3
This commit is contained in:
parent
7eed146bb2
commit
a80891d3df
11
.github/workflows/auto-build.yml
vendored
11
.github/workflows/auto-build.yml
vendored
@ -39,6 +39,9 @@ on:
|
|||||||
- rutorrent
|
- rutorrent
|
||||||
- swag
|
- swag
|
||||||
- thelounge
|
- thelounge
|
||||||
|
append-tag:
|
||||||
|
required: false
|
||||||
|
description: 'Append a the tag with "-custom" e.g :radarr-testing'
|
||||||
jobs:
|
jobs:
|
||||||
push_to_ghcr_io:
|
push_to_ghcr_io:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@ -76,8 +79,8 @@ jobs:
|
|||||||
- name: manually build
|
- name: manually build
|
||||||
if: ${{ github.event.inputs.app }}
|
if: ${{ github.event.inputs.app }}
|
||||||
run: |
|
run: |
|
||||||
docker build docker-mods/${{ github.event.inputs.app }} --tag ghcr.io/gilbn/theme.park:${{ github.event.inputs.app }}
|
docker build docker-mods/${{ github.event.inputs.app }} --tag ghcr.io/gilbn/theme.park:${{ github.event.inputs.app }}${{ github.event.inputs.append-tag }}
|
||||||
docker push ghcr.io/gilbn/theme.park:${{ github.event.inputs.app }}
|
docker push ghcr.io/gilbn/theme.park:${{ github.event.inputs.app }}${{ github.event.inputs.append-tag }}
|
||||||
push_to_dockerhub:
|
push_to_dockerhub:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
@ -113,5 +116,5 @@ jobs:
|
|||||||
- name: manually build
|
- name: manually build
|
||||||
if: ${{ github.event.inputs.app }}
|
if: ${{ github.event.inputs.app }}
|
||||||
run: |
|
run: |
|
||||||
docker build docker-mods/${{ github.event.inputs.app }} --tag gilbn/theme.park:${{ github.event.inputs.app }}
|
docker build docker-mods/${{ github.event.inputs.app }} --tag gilbn/theme.park:${{ github.event.inputs.app }}${{ github.event.inputs.append-tag }}
|
||||||
docker push gilbn/theme.park:${{ github.event.inputs.app }}
|
docker push gilbn/theme.park:${{ github.event.inputs.app }}${{ github.event.inputs.append-tag }}
|
62
docker-mods/bazarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
62
docker-mods/bazarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,62 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Bazarr theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_ADDON'=${TP_ADDON}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/bazarr/bin/frontend/build/index.html'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/bin/frontend/build/index.html'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/bazarr\/bazarr-base.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
||||||
|
if [[ -n ${TP_ADDON} ]]; then
|
||||||
|
for addon in $(echo "$TP_ADDON" | tr "|" " "); do
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/bazarr\/${addon}\/${addon}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
printf 'Added custom addon: %s\n\n' "${addon}"
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
50
docker-mods/calibre-web/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
50
docker-mods/calibre-web/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '--------------------------------'
|
||||||
|
echo '| Calibre-web theme.park Mod |'
|
||||||
|
echo '--------------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /app/calibre-web/cps/templates/layout.html; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/calibreweb\/calibreweb-base.css'><\/head> /g" /app/calibre-web/cps/templates/layout.html
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" /app/calibre-web/cps/templates/layout.html
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
51
docker-mods/deluge/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
51
docker-mods/deluge/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,51 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Deluge theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
DELUGE_INDEX_PATH=$(find /usr -name index.html)
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" ${DELUGE_INDEX_PATH}; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/deluge\/deluge-base.css'><\/head> /g" ${DELUGE_INDEX_PATH}
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" ${DELUGE_INDEX_PATH}
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
60
docker-mods/duplicati/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
60
docker-mods/duplicati/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,60 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '----------------------------'
|
||||||
|
echo '| Duplicati theme.park Mod |'
|
||||||
|
echo '----------------------------'
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/duplicati/webroot'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'APP_FILEPATH'=${APP_FILEPATH}\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed_file(){
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/duplicati\/duplicati-base.css'><\/head> /g" $1
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" $1
|
||||||
|
printf 'Stylesheet set to %s on %s\n\n' "${TP_THEME}" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
echo '---------------------------------------'
|
||||||
|
echo '| Adding the stylesheet to html files |'
|
||||||
|
echo '---------------------------------------'
|
||||||
|
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}/index.html"; then
|
||||||
|
find ${APP_FILEPATH} -type f -iname *.html | while read fname
|
||||||
|
do
|
||||||
|
sed_file $fname
|
||||||
|
done
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
43
docker-mods/emby/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
43
docker-mods/emby/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,43 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '-------------------------'
|
||||||
|
echo '| Emby theme.park Mod |'
|
||||||
|
echo '-------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
printf '%s\n' "@import url('${TP_SCHEME}://${TP_DOMAIN}/css/${THEME_TYPE}/${TP_THEME}.css');" "@import url('${TP_SCHEME}://${TP_DOMAIN}/css/base/emby/emby-base.css');" > /app/emby/dashboard-ui/modules/themes/light/theme.css
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
56
docker-mods/jackett/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
56
docker-mods/jackett/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,56 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Jackett theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/Jackett/Content/index.html'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/Content/index.html'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/jackett\/jackett-base.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
50
docker-mods/jellyfin/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
50
docker-mods/jellyfin/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '-----------------------------'
|
||||||
|
echo '| Jellyfin theme.park Mod |'
|
||||||
|
echo '-----------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /usr/share/jellyfin/web/index.html; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/body>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/jellyfin\/jellyfin-base.css'><\/body> /g" /usr/share/jellyfin/web/index.html
|
||||||
|
sed -i "s/<\/body>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/body> /g" /usr/share/jellyfin/web/index.html
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
50
docker-mods/lazylibrarian/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
50
docker-mods/lazylibrarian/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '----------------------------------'
|
||||||
|
echo '| Lazylibrarian theme.park Mod |'
|
||||||
|
echo '----------------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /app/lazylibrarian/data/interfaces/bookstrap/base.html; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/lazylibrarian\/lazylibrarian-base.css'><\/head> /g" /app/lazylibrarian/data/interfaces/bookstrap/base.html
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" /app/lazylibrarian/data/interfaces/bookstrap/base.html
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
50
docker-mods/librespeed/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
50
docker-mods/librespeed/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,50 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '-------------------------------'
|
||||||
|
echo '| Librespeed theme.park Mod |'
|
||||||
|
echo '-------------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /app/www/public/index.html; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/librespeed\/librespeed-base.css'><\/head> /g" /usr/share/webapps/librespeed/index.html
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" /usr/share/webapps/librespeed/index.html
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}
|
||||||
|
"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
67
docker-mods/lidarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
67
docker-mods/lidarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,67 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Lidarr theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_ADDON'=${TP_ADDON}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/lidarr/bin/UI/index.html'
|
||||||
|
LOGIN_FILEPATH='/app/lidarr/bin/UI/login.html'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/bin/UI/index.html'
|
||||||
|
LOGIN_FILEPATH='/app/bin/UI/login.html'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/lidarr\/lidarr-base.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/lidarr\/lidarr-base.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
||||||
|
if [[ -n ${TP_ADDON} ]]; then
|
||||||
|
for addon in $(echo "$TP_ADDON" | tr "|" " "); do
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/lidarr\/${addon}\/${addon}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/lidarr\/${addon}\/${addon}.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
printf 'Added custom addon: %s\n\n' "${addon}"
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
65
docker-mods/mylar3/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
65
docker-mods/mylar3/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,65 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '-------------------------'
|
||||||
|
echo '| Mylar3 theme.park Mod |'
|
||||||
|
echo '-------------------------'
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/mylar3/data/interfaces/default'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/data/interfaces/default'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'APP_FILEPATH'=${APP_FILEPATH}\\n\
|
||||||
|
'TP_HOTIO'=${TP_HOTIO}\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed_file(){
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/mylar3\/mylar3-base.css'><\/head> /g" $1
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" $1
|
||||||
|
printf 'Stylesheet set to %s on %s\n\n' "${TP_THEME}" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
echo '---------------------------------------'
|
||||||
|
echo '| Adding the stylesheet to html files |'
|
||||||
|
echo '---------------------------------------'
|
||||||
|
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}/index.html"; then
|
||||||
|
find ${APP_FILEPATH} -type f -iname *.html | while read fname
|
||||||
|
do
|
||||||
|
sed_file $fname
|
||||||
|
done
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
@ -0,0 +1,63 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '--------------------------------------'
|
||||||
|
echo '| Nginx Proxy Manager theme.park Mod |'
|
||||||
|
echo '--------------------------------------'
|
||||||
|
|
||||||
|
if [[ -d "/app/frontend" ]]; then
|
||||||
|
APP_FILEPATH='/app/frontend/' # jc21/nginx-proxy-manager
|
||||||
|
else
|
||||||
|
APP_FILEPATH='/opt/nginx-proxy-manager/frontend/' # jlesage/nginx-proxy-manager
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'APP_FILEPATH'=${APP_FILEPATH}\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed_file(){
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/nginx-proxy-manager\/nginx-proxy-manager-base.css'><\/head> /g" $1
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" $1
|
||||||
|
printf 'Stylesheet set to %s on %s\n\n' "${TP_THEME}" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}/index.html"; then
|
||||||
|
echo '---------------------------------------'
|
||||||
|
echo '| Adding the stylesheet to html files |'
|
||||||
|
echo '---------------------------------------'
|
||||||
|
find ${APP_FILEPATH} -type f -iname *.html | while read fname
|
||||||
|
do
|
||||||
|
sed_file $fname
|
||||||
|
done
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
54
docker-mods/nzbget/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
54
docker-mods/nzbget/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,54 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| NZBGet theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/nzbget/webui/index.html'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/webui/index.html'
|
||||||
|
fi
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/nzbget\/nzbget-base.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
61
docker-mods/plex/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
61
docker-mods/plex/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,61 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '-------------------------'
|
||||||
|
echo '| Plex theme.park Mod |'
|
||||||
|
echo '-------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH=''
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"/usr/lib/plexmediaserver/Resources/Plug-ins-*/WebClient.bundle/Contents/Resources/index.html; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/plex\/plex-base.css'><\/head> /g" "${APP_FILEPATH}"/usr/lib/plexmediaserver/Resources/Plug-ins-*/WebClient.bundle/Contents/Resources/index.html
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"/usr/lib/plexmediaserver/Resources/Plug-ins-*/WebClient.bundle/Contents/Resources/index.html
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
||||||
|
if [[ -n ${TP_ADDON} ]]; then
|
||||||
|
for addon in $(echo "$TP_ADDON" | tr "|" " "); do
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/plex\/${addon}\/${addon}.css'><\/head> /g" "${APP_FILEPATH}"/usr/lib/plexmediaserver/Resources/Plug-ins-*/WebClient.bundle/Contents/Resources/index.html
|
||||||
|
printf 'Added custom addon: %s\n\n' "${addon}"
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
67
docker-mods/prowlarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
67
docker-mods/prowlarr/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,67 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Prowlarr theme.park Mod |'
|
||||||
|
echo '---------------------------'
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_ADDON'=${TP_ADDON}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
APP_FILEPATH='/app/prowlarr/bin/UI/index.html'
|
||||||
|
LOGIN_FILEPATH='/app/prowlarr/bin/UI/login.html'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/app/bin/UI/index.html'
|
||||||
|
LOGIN_FILEPATH='/app/bin/UI/login.html'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" "${APP_FILEPATH}"; then
|
||||||
|
echo '---------------------------'
|
||||||
|
echo '| Adding the stylesheet |'
|
||||||
|
echo '---------------------------'
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/prowlarr\/prowlarr-base.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/prowlarr\/prowlarr-base.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
printf 'Stylesheet set to %s\n' "${TP_THEME}"
|
||||||
|
if [[ -n ${TP_ADDON} ]]; then
|
||||||
|
for addon in $(echo "$TP_ADDON" | tr "|" " "); do
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/prowlarr\/${addon}\/${addon}.css'><\/head> /g" "${APP_FILEPATH}"
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/addons\/prowlarr\/${addon}\/${addon}.css'><\/head> /g" "${LOGIN_FILEPATH}"
|
||||||
|
printf 'Added custom addon: %s\n\n' "${addon}"
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
@ -0,0 +1,5 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
if ! [[ -x "$(command -v svn)" ]]; then
|
||||||
|
echo "subversion" >> /mod-repo-packages-to-install.list
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark-add-package/run
|
122
docker-mods/qbittorrent/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
122
docker-mods/qbittorrent/root/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
Executable file
@ -0,0 +1,122 @@
|
|||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
echo '------------------------------'
|
||||||
|
echo '| qBittorrent theme.park Mod |'
|
||||||
|
echo '------------------------------'
|
||||||
|
|
||||||
|
APP_FILEPATH='/config/qBittorrent/qBittorrent.conf'
|
||||||
|
if [ "${TP_HOTIO}" = true ]; then
|
||||||
|
echo 'Changing to Hotio file path!'
|
||||||
|
APP_FILEPATH='/config/config/qBittorrent.conf'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Backup config
|
||||||
|
if [[ ! -f "${APP_FILEPATH}.bak" ]]; then
|
||||||
|
echo "Creating qBittorrent.conf backup in /config."
|
||||||
|
cp -p ${APP_FILEPATH} "${APP_FILEPATH}.bak"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Restore qBittorrent.conf
|
||||||
|
if [ "${TP_DISABLE_THEME}" = true ]; then
|
||||||
|
echo "Restoring backup of qBittorrent.conf"
|
||||||
|
sed -i "s/WebUI\\\AlternativeUIEnabled=.*$/WebUI\\\AlternativeUIEnabled=false/g" "${APP_FILEPATH}";
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Display variables for troubleshooting
|
||||||
|
echo -e "Variables set:\\n\
|
||||||
|
'APP_FILEPATH'=${APP_FILEPATH}\\n\
|
||||||
|
'TP_DISABLE_THEME'=${TP_DISABLE_THEME}\\n\
|
||||||
|
'TP_HOTIO'=${TP_HOTIO}\\n\
|
||||||
|
'TP_DOMAIN'=${TP_DOMAIN}\\n\
|
||||||
|
'TP_COMMUNITY_THEME'=${TP_COMMUNITY_THEME}\\n\
|
||||||
|
'TP_SCHEME'=${TP_SCHEME}\\n\
|
||||||
|
'TP_THEME'=${TP_THEME}\\n"
|
||||||
|
|
||||||
|
# Set default
|
||||||
|
if [[ -z ${TP_DOMAIN} ]]; then
|
||||||
|
echo 'No domain set, defaulting to theme-park.dev'
|
||||||
|
TP_DOMAIN='theme-park.dev'
|
||||||
|
fi
|
||||||
|
if [[ -z ${TP_SCHEME} ]]; then
|
||||||
|
echo 'No scheme set, defaulting to https'
|
||||||
|
TP_SCHEME='https'
|
||||||
|
fi
|
||||||
|
|
||||||
|
THEME_TYPE='theme-options'
|
||||||
|
if [ "${TP_COMMUNITY_THEME}" = true ]; then
|
||||||
|
THEME_TYPE='community-theme-options'
|
||||||
|
fi
|
||||||
|
|
||||||
|
case ${TP_DOMAIN} in
|
||||||
|
*"github.io"*)
|
||||||
|
echo "Switching to github.io URL style"
|
||||||
|
TP_DOMAIN="${TP_DOMAIN}\/theme.park"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [[ -z ${TP_THEME} ]]; then
|
||||||
|
echo 'No theme set, defaulting to organizr'
|
||||||
|
TP_THEME='organizr'
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Downloading fresh webui files from source.
|
||||||
|
if [[ ! -d /themepark ]]; then
|
||||||
|
echo '---------------------------------------'
|
||||||
|
echo '| Downloading WebUI files from github |'
|
||||||
|
echo '---------------------------------------'
|
||||||
|
printf '\nDownloading qBittorrent webui to "/themepark"..please wait\n'
|
||||||
|
svn export --quiet https://github.com/qbittorrent/qBittorrent/trunk/src/webui/www /themepark
|
||||||
|
printf '\nDownload finished\n\n'
|
||||||
|
printf '\nDownloading qBittorrent webui icons to "/themepark/xxx"..please wait\n'
|
||||||
|
svn export --force --quiet https://github.com/qbittorrent/qBittorrent/trunk/src/icons /temp
|
||||||
|
cp -a /temp/. /themepark/public/icons
|
||||||
|
cp -a /temp/. /themepark/private/icons
|
||||||
|
rm -rf /temp
|
||||||
|
printf '\nDownload finished\n\n'
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed_file(){
|
||||||
|
sed -i "s/<\/body>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/qbittorrent\/qbittorrent-base.css'><\/body> /g" $1
|
||||||
|
sed -i "s/<\/body>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/body> /g" $1
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/base\/qbittorrent\/qbittorrent-base.css'><\/head> /g" $1
|
||||||
|
sed -i "s/<\/head>/<link rel='stylesheet' href='${TP_SCHEME}:\/\/${TP_DOMAIN}\/css\/${THEME_TYPE}\/${TP_THEME}.css'><\/head> /g" $1
|
||||||
|
printf 'Stylesheet set to %s on %s\n\n' "${TP_THEME}" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# Adding stylesheets
|
||||||
|
echo '---------------------------------------'
|
||||||
|
echo '| Adding the stylesheet to html files |'
|
||||||
|
echo '---------------------------------------'
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /themepark/public/index.html; then
|
||||||
|
sed_file /themepark/public/index.html
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! grep -q "${TP_DOMAIN}/css/base" /themepark/private/index.html; then
|
||||||
|
find /themepark/private -type f -iname *.html | while read fname
|
||||||
|
do
|
||||||
|
sed_file $fname
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! grep -q "WebUI\\\RootFolder" "${APP_FILEPATH}"; then
|
||||||
|
echo '--------------------------------------'
|
||||||
|
echo '| Adding WebUI\RootFolder=/themepark |'
|
||||||
|
echo '--------------------------------------'
|
||||||
|
sed -i -e '$aWebUI\\RootFolder=/themepark' "${APP_FILEPATH}";
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! grep -q "WebUI\\\AlternativeUIEnabled" "${APP_FILEPATH}"; then
|
||||||
|
echo '------------------------------------------'
|
||||||
|
echo '| Adding WebUI\AlternativeUIEnabled=true |'
|
||||||
|
echo '------------------------------------------'
|
||||||
|
sed -i -e '$aWebUI\\AlternativeUIEnabled=true' "${APP_FILEPATH}";
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! grep -q "WebUI\\\RootFolder=/themepark" "${APP_FILEPATH}" || ! grep -q "WebUI\\\AlternativeUIEnabled=true" "${APP_FILEPATH}"; then
|
||||||
|
echo '-------------------------------------------------------'
|
||||||
|
echo '| Updating RootFolder and AlternativeUIEnabled values |'
|
||||||
|
echo '-------------------------------------------------------'
|
||||||
|
sed -i "s/WebUI\\\AlternativeUIEnabled=.*$/WebUI\\\AlternativeUIEnabled=true/g" "${APP_FILEPATH}";
|
||||||
|
sed -i "s/WebUI\\\RootFolder=.*$/WebUI\\\RootFolder=\/themepark/g" "${APP_FILEPATH}";
|
||||||
|
fi
|
@ -0,0 +1 @@
|
|||||||
|
oneshot
|
@ -0,0 +1 @@
|
|||||||
|
/etc/s6-overlay/s6-rc.d/init-mod-themepark/run
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user