-
Notifications
You must be signed in to change notification settings - Fork 68
/
repair.sh
39 lines (26 loc) · 806 Bytes
/
repair.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
if (( $EUID != 0 )); then
echo "Please run as root"
exit
fi
repairPanel(){
cd /var/www/pterodactyl
php artisan down
rm -r /var/www/pterodactyl/resources
curl -L https://github.com/pterodactyl/panel/releases/latest/download/panel.tar.gz | tar -xzv
chmod -R 755 storage/* bootstrap/cache
composer install --no-dev --optimize-autoloader
php artisan view:clear
php artisan config:clear
php artisan migrate --seed --force
chown -R www-data:www-data /var/www/pterodactyl/*
php artisan queue:restart
php artisan up
}
while true; do
read -p "Are you sure that you want to unninstall the theme [y/n]? " yn
case $yn in
[Yy]* ) repairPanel; break;;
[Nn]* ) exit;;
* ) echo "Please answer yes or no.";;
esac
done