Test tinyauth

This commit is contained in:
tremor021 2025-06-10 18:25:53 +02:00
parent b276ec69a0
commit 484c3be103

View File

@ -1,5 +1,5 @@
#!/usr/bin/env bash
source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)
source <(curl -s https://raw.githubusercontent.com/community-scripts/ProxmoxVED/main/misc/build.func)
# Copyright (c) 2021-2025 community-scripts ORG
# Author: Slaviša Arežina (tremor021) | Co-Author: Stavros (steveiliop56)
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
@ -31,13 +31,13 @@ function update_script() {
msg_info "Updating Tinyauth"
RELEASE=$(curl -s https://api.github.com/repos/steveiliop56/tinyauth/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
if [ "${RELEASE}" != "$(cat /opt/tinyauth_version.txt)" ] || [ ! -f /opt/tinyauth_version.txt ]; then
$STD service tinyauth stop
rm -f /opt/tinyauth/tinyauth
curl -fsSL "https://github.com/steveiliop56/tinyauth/releases/download/v${RELEASE}/tinyauth-amd64" -o /opt/tinyauth/tinyauth
chmod +x /opt/tinyauth/tinyauth
echo "${RELEASE}" > /opt/tinyauth_version.txt
echo "${RELEASE}" >/opt/tinyauth_version.txt
msg_info "Restarting Tinyauth"
$STD service tinyauth start
msg_ok "Restarted Tinyauth"