mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-10-04 01:53:13 +02:00
several scripts: use the release helpers instead of hand-rolled version checks and downloads (#17625)
* Use the release helpers instead of hand-rolled version checks and downloads Legacy /opt/*_version.txt files move to ~/.<app> on the next update. * homeassistant: use get_latest_github_release
This commit is contained in:
committed by
GitHub
parent
94cdc531ca
commit
b4bf7aacf3
@@ -64,11 +64,9 @@ setup_alpine() {
|
||||
$STD apk add --no-cache openssl apache2-utils
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
msg_info "Installing Tinyauth"
|
||||
mkdir -p /opt/tinyauth
|
||||
RELEASE=$(curl -s https://api.github.com/repos/tinyauthapp/tinyauth/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||
curl -fsSL "https://github.com/tinyauthapp/tinyauth/releases/download/v${RELEASE}/tinyauth-$(arch_resolve)" -o /opt/tinyauth/tinyauth
|
||||
chmod +x /opt/tinyauth/tinyauth
|
||||
fetch_and_deploy_gh_release "tinyauth" "tinyauthapp/tinyauth" "singlefile" "latest" "/opt/tinyauth" "tinyauth-$(arch_resolve)"
|
||||
|
||||
msg_info "Configuring Tinyauth"
|
||||
PASS=$(openssl rand -base64 8 | tr -dc 'a-zA-Z0-9' | head -c 8)
|
||||
USER=$(htpasswd -Bbn "tinyauth" "${PASS}")
|
||||
|
||||
@@ -77,8 +75,7 @@ Tinyauth Credentials
|
||||
Username: tinyauth
|
||||
Password: ${PASS}
|
||||
EOF
|
||||
echo "${RELEASE}" >~/.tinyauth
|
||||
msg_ok "Installed Tinyauth"
|
||||
msg_ok "Configured Tinyauth"
|
||||
|
||||
read -r -p "${TAB3}Enter your Tinyauth subdomain (e.g. https://tinyauth.example.com): " app_url
|
||||
|
||||
|
||||
Reference in New Issue
Block a user