Fix UA ordering

This commit is contained in:
TheSpad 2023-05-25 09:26:14 +01:00
parent 851ab3898f
commit 4baffb04af
No known key found for this signature in database
GPG Key ID: 08F06191F4587860

View File

@ -1,12 +1,11 @@
#!/command/with-contenv bash
# shellcheck shell=bash
# Use /command/with-contenv shebang because /usr/bin/with-contenv is created in this script
# Version 3
# 2022-09-25
MOD_SCRIPT_VER="3"
MOD_UA="Mozilla/5.0 (Linux $(uname -m)) linuxserver.io ${MANIFEST_URL}:${TAG}"
# Use /command/with-contenv shebang because /usr/bin/with-contenv is created in this script
# Define custom folder paths
SCRIPTS_DIR="/custom-cont-init.d"
@ -252,6 +251,7 @@ run_mods() {
FILENAME="${USERNAME}.${REPO}.${TAG}"
MANIFEST_URL="https://${REGISTRY}/v2/${ENDPOINT}/manifests"
BLOB_URL="https://${REGISTRY}/v2/${ENDPOINT}/blobs/"
MOD_UA="Mozilla/5.0 (Linux $(uname -m)) linuxserver.io ${MANIFEST_URL}:${TAG}"
case "${REGISTRY}" in
"lscr.io") AUTH_URL="https://ghcr.io/token?scope=repository%3A${USERNAME}%2F${REPO}%3Apull";;
"ghcr.io") AUTH_URL="https://ghcr.io/token?scope=repository%3A${USERNAME}%2F${REPO}%3Apull";;