mirror of
https://github.com/tommytran732/Pterodactyl-Script
synced 2024-11-22 18:41:32 -05:00
Update Wings
Update wings 0.6.13 to 1.0.0-rc.5
This commit is contained in:
parent
713e68a194
commit
fcde92c70a
56
install.sh
56
install.sh
@ -160,7 +160,7 @@ install_options(){
|
|||||||
output "[2] Install the daemon."
|
output "[2] Install the daemon."
|
||||||
output "[3] Install the panel and daemon."
|
output "[3] Install the panel and daemon."
|
||||||
output "[4] Upgrade 1.0.0-rc.x RC panel to 1.0.0-rc.5."
|
output "[4] Upgrade 1.0.0-rc.x RC panel to 1.0.0-rc.5."
|
||||||
output "[5] Upgrade 0.6.x daemon to 0.6.13."
|
output "[5] Upgrade 1.0.0-rc.x daemon to 1.0.0-rc.5."
|
||||||
output "[6] Upgrade the panel to 1.0.0-rc.x and daemon to 1.0.0-rc.5"
|
output "[6] Upgrade the panel to 1.0.0-rc.x and daemon to 1.0.0-rc.5"
|
||||||
output "[7] Make Pterodactyl compatible with the mobile app (only use this after you have installed the panel - check out https://pterodactyl.cloud for more information)."
|
output "[7] Make Pterodactyl compatible with the mobile app (only use this after you have installed the panel - check out https://pterodactyl.cloud for more information)."
|
||||||
output "[8] Update mobile compatibility."
|
output "[8] Update mobile compatibility."
|
||||||
@ -870,55 +870,24 @@ install_daemon() {
|
|||||||
systemctl enable docker
|
systemctl enable docker
|
||||||
output "Enabling SWAP support for Docker & installing NodeJS..."
|
output "Enabling SWAP support for Docker & installing NodeJS..."
|
||||||
sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="[^"]*/& swapaccount=1/' /etc/default/grub
|
sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="[^"]*/& swapaccount=1/' /etc/default/grub
|
||||||
if [ "$lsb_dist" = "ubuntu" ] || [ "$lsb_dist" = "debian" ]; then
|
|
||||||
update-grub
|
|
||||||
curl -sL https://deb.nodesource.com/setup_12.x | sudo bash -
|
|
||||||
if [ "$lsb_dist" = "ubuntu" ] && [ "$dist_version" = "20.04" ]; then
|
|
||||||
apt -y install nodejs make gcc g++
|
|
||||||
npm install node-gyp
|
|
||||||
elif [ "$lsb_dist" = "debian" ] && [ "$dist_version" = "10" ]; then
|
|
||||||
apt -y install nodejs make gcc g++
|
|
||||||
else
|
|
||||||
apt -y install nodejs make gcc g++ node-gyp
|
|
||||||
fi
|
|
||||||
apt-get -y update
|
|
||||||
apt-get -y upgrade
|
|
||||||
apt-get -y autoremove
|
|
||||||
apt-get -y autoclean
|
|
||||||
elif [ "$lsb_dist" = "fedora" ] || [ "$lsb_dist" = "centos" ]; then
|
|
||||||
grub2-mkconfig -o "$(readlink /etc/grub2.conf)"
|
|
||||||
if [ "$lsb_dist" = "fedora" ]; then
|
|
||||||
dnf -y module install nodejs:12/minimal
|
|
||||||
dnf install -y tar unzip make gcc gcc-c++ python2
|
|
||||||
elif [ "$lsb_dist" = "centos" ] && [ "$dist_version" = "8" ]; then
|
|
||||||
dnf -y module install nodejs:12/minimal
|
|
||||||
dnf install -y tar unzip make gcc gcc-c++ python2
|
|
||||||
elif [ "$lsb_dist" = "centos" ] && [ "$dist_version" = "7" ]; then
|
|
||||||
curl --silent --location https://rpm.nodesource.com/setup_12.x | sudo bash -
|
|
||||||
yum -y install nodejs tar unzip make gcc-c++ node-gyp
|
|
||||||
fi
|
|
||||||
yum -y upgrade
|
|
||||||
yum -y autoremove
|
|
||||||
yum -y clean packages
|
|
||||||
fi
|
|
||||||
output "Installing the Pterodactyl daemon..."
|
output "Installing the Pterodactyl daemon..."
|
||||||
mkdir -p /srv/daemon /srv/daemon-data
|
mkdir -p /etc/pterodactyl
|
||||||
cd /srv/daemon
|
curl -L -o /usr/local/bin/wings https://github.com/pterodactyl/wings/releases/download/v1.0.0-rc.5/wings_linux_amd64
|
||||||
curl -L https://github.com/pterodactyl/daemon/releases/download/v0.6.13/daemon.tar.gz | tar --strip-components=1 -xzv
|
chmod u+x /usr/local/bin/wings
|
||||||
npm install --only=production --no-audit --unsafe-perm
|
|
||||||
bash -c 'cat > /etc/systemd/system/wings.service' <<-'EOF'
|
bash -c 'cat > /etc/systemd/system/wings.service' <<-'EOF'
|
||||||
[Unit]
|
[Unit]
|
||||||
Description=Pterodactyl Wings Daemon
|
Description=Pterodactyl Wings Daemon
|
||||||
After=docker.service
|
After=docker.service
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
User=root
|
User=root
|
||||||
#Group=some_group
|
WorkingDirectory=/etc/pterodactyl
|
||||||
WorkingDirectory=/srv/daemon
|
|
||||||
LimitNOFILE=4096
|
LimitNOFILE=4096
|
||||||
PIDFile=/var/run/wings/daemon.pid
|
PIDFile=/var/run/wings/daemon.pid
|
||||||
ExecStart=/usr/bin/node /srv/daemon/src/index.js
|
ExecStart=/usr/local/bin/wings
|
||||||
Restart=on-failure
|
Restart=on-failure
|
||||||
StartLimitInterval=600
|
StartLimitInterval=600
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
EOF
|
EOF
|
||||||
@ -934,13 +903,10 @@ EOF
|
|||||||
}
|
}
|
||||||
|
|
||||||
upgrade_daemon(){
|
upgrade_daemon(){
|
||||||
cd /srv/daemon
|
curl -L -o /usr/local/bin/wings https://github.com/pterodactyl/wings/releases/download/v1.0.0-rc.5/wings_linux_amd64
|
||||||
service wings stop
|
chmod u+x /usr/local/bin/wings
|
||||||
curl -L https://github.com/pterodactyl/daemon/releases/download/v0.6.13/daemon.tar.gz | tar --strip-components=1 -xzv
|
|
||||||
npm install -g npm
|
|
||||||
npm install --only=production --no-audit --unsafe-perm
|
|
||||||
service wings restart
|
service wings restart
|
||||||
output "Your daemon has been updated to version 0.6.13."
|
output "Your daemon has been updated to version 1.0.0-rc.5."
|
||||||
output "npm has been updated to the latest version."
|
output "npm has been updated to the latest version."
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user