This commit is contained in:
Slaviša Arežina 2025-12-17 16:27:16 +01:00 committed by GitHub
parent 4b3ebfc8ec
commit 39821677f0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 6 additions and 17 deletions

View File

@ -23,29 +23,23 @@ function update_script() {
header_info
check_container_storage
check_container_resources
if [[ ! -f /usr/local/bin/wings ]]; then
if [[ ! -x /usr/local/bin/wings ]]; then
msg_error "No ${APP} Installation Found!"
exit
fi
RELEASE=$(curl -fsSL https://api.github.com/repos/pterodactyl/wings/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
if [[ ! -f /opt/${APP}_version.txt ]] || [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]]; then
if check_for_gh_release "wings" "pterodactyl/wings"; then
msg_info "Stopping Service"
systemctl stop wings
msg_ok "Stopped Service"
msg_info "Updating ${APP} to v${RELEASE}"
rm /usr/local/bin/wings
curl -fsSL "https://github.com/pterodactyl/wings/releases/download/v${RELEASE}/wings_linux_amd64" -o "/usr/local/bin/wings"
chmod u+x /usr/local/bin/wings
echo "${RELEASE}" >/opt/${APP}_version.txt
msg_ok "Updated $APP to v${RELEASE}"
fetch_and_deploy_gh_release "wings" "pterodactyl/wings" "singlefile" "latest" "/usr/local/bin" "wings_linux_amd64"
msg_info "Starting Service"
systemctl start wings
msg_ok "Started Service"
msg_ok "Updated successfully!"
else
msg_ok "No update required. ${APP} is already at v${RELEASE}"
fi
exit
}

View File

@ -12,7 +12,7 @@
"documentation": "https://pterodactyl.io/wings/1.0/installing.html",
"website": "https://pterodactyl.io",
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons@main/webp/pterodactyl.webp",
"config_path": "",
"config_path": "/etc/pterodactyl/config.yml",
"description": "Pterodactyl Wings is Pterodactyl's server control plane, built for the rapidly changing gaming industry and designed to be highly performant and secure. Wings provides an HTTP API allowing you to interface directly with running server instances, fetch server logs, generate backups, and control all aspects of the server lifecycle.",
"install_methods": [
{

View File

@ -21,13 +21,8 @@ $STD sh <(curl -fsSL https://get.docker.com)
systemctl enable -q --now docker
msg_ok "Installed Docker"
msg_info "Installing Pterodactyl Wings"
RELEASE=$(curl -fsSL https://api.github.com/repos/pterodactyl/wings/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
curl -fsSL "https://github.com/pterodactyl/wings/releases/download/v${RELEASE}/wings_linux_amd64" -o "/usr/local/bin/wings"
chmod u+x /usr/local/bin/wings
fetch_and_deploy_gh_release "wings" "pterodactyl/wings" "singlefile" "latest" "/usr/local/bin" "wings_linux_amd64"
mkdir -p /etc/pterodactyl
echo "${RELEASE}" >/opt/${APPLICATION}_version.txt
msg_ok "Installed Pterodactyl Wings"
msg_info "Creating Service"
cat <<EOF >/etc/systemd/system/wings.service