1
0
mirror of https://github.com/tommytran732/Pterodactyl-Script synced 2024-11-22 18:41:32 -05:00
This commit is contained in:
HeyJack 2020-10-12 04:26:58 +01:00
parent df09c74fdb
commit 7003f26c62

View File

@ -42,9 +42,9 @@ preflight(){
apt-get -y install virt-what curl apt-get -y install virt-what curl
elif [ "$lsb_dist" = "debian" ]; then elif [ "$lsb_dist" = "debian" ]; then
apt update --fix-missing apt update --fix-missing
apt-get -y install software-properties-common virt-what wget curl apt-get -y install software-properties-common virt-what wget curl dnsutils
elif [ "$lsb_dist" = "fedora" ] || [ "$lsb_dist" = "centos" ] || [ "$lsb_dist" = "rhel" ]; then elif [ "$lsb_dist" = "fedora" ] || [ "$lsb_dist" = "centos" ] || [ "$lsb_dist" = "rhel" ]; then
yum -y install virt-what wget yum -y install virt-what wget bind-utils
fi fi
virt_serv=$(echo $(virt-what)) virt_serv=$(echo $(virt-what))
if [ "$virt_serv" = "" ]; then if [ "$virt_serv" = "" ]; then
@ -160,7 +160,7 @@ install_options(){
output "[2] Install the panel (0.7.19)." output "[2] Install the panel (0.7.19)."
output "[3] Install the wings." output "[3] Install the wings."
output "[4] Install the daemon." output "[4] Install the daemon."
output "[5] Install the (1.0) panel and daemon." output "[5] Install the (1.0) panel and wings."
output "[6] Install the (0.7.19) panel and daemon." output "[6] Install the (0.7.19) panel and daemon."
output "[7] Install the standalone SFTP server." output "[7] Install the standalone SFTP server."
output "[8] Upgrade (0.7.x) panel to (1.0)." output "[8] Upgrade (0.7.x) panel to (1.0)."
@ -1310,17 +1310,13 @@ install_wings() {
service docker start service docker start
systemctl enable docker systemctl enable docker
output "Enabling SWAP support for Docker & installing NodeJS..." output "Enabling SWAP support for Docker."
sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="[^"]*/& swapaccount=1/' /etc/default/grub sed -i 's/GRUB_CMDLINE_LINUX_DEFAULT="[^"]*/& swapaccount=1/' /etc/default/grub
mkdir -p /etc/pterodactyl output "Installing the Pterodactyl wings..."
mkdir -p /etc/pterodactyl /srv/daemon-data
cd /etc/pterodactyl
curl -L -o /usr/local/bin/wings https://github.com/pterodactyl/wings/releases/download/v1.0.0/wings_linux_amd64 curl -L -o /usr/local/bin/wings https://github.com/pterodactyl/wings/releases/download/v1.0.0/wings_linux_amd64
chmod u+x /usr/local/bin/wings chmod u+x /usr/local/bin/wings
output "Installing the Pterodactyl daemon..."
mkdir -p /srv/daemon /srv/daemon-data
cd /srv/daemon
curl -L https://github.com/pterodactyl/daemon/releases/download/v0.6.13/daemon.tar.gz | tar --strip-components=1 -xzv
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
@ -1345,7 +1341,7 @@ EOF
output "Paste your auto deploy command below: " output "Paste your auto deploy command below: "
read AUTODEPLOY read AUTODEPLOY
${AUTODEPLOY} ${AUTODEPLOY}
service wings start sudo wings
} }
install_daemon() { install_daemon() {