2023-03-03 10:52:29 -05:00
|
|
|
#!/bin/bash
|
|
|
|
|
2023-03-06 13:11:53 -05:00
|
|
|
cd /var/www/pterodactyl;
|
2023-03-17 10:47:28 -04:00
|
|
|
if [[ "$@" == *"-php"* ]]; then
|
2023-03-08 04:44:53 -05:00
|
|
|
exit 1;
|
|
|
|
fi;
|
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
mkdir .blueprint 2> /dev/null;
|
|
|
|
cp -R blueprint/* .blueprint/ 2> /dev/null;
|
|
|
|
rm -R blueprint 2> /dev/null;
|
2023-03-06 13:11:53 -05:00
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
source .blueprint/lib/bash_colors.sh;
|
|
|
|
source .blueprint/lib/db.sh
|
2023-03-03 10:52:29 -05:00
|
|
|
|
2023-03-18 06:24:16 -04:00
|
|
|
if [[ $1 != "-bash" ]]; then
|
2023-03-03 10:52:29 -05:00
|
|
|
if dbValidate "blueprint.setupFinished"; then
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_blue "This command only works if you have yet to install Blueprint. You can run \"\033[1;94mblueprint\033[0m\033[0;34m\" instead.";
|
2023-03-03 11:00:03 -05:00
|
|
|
dbRemove "blueprint.setupFinished";
|
2023-03-03 10:52:29 -05:00
|
|
|
else
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_bright "/var/www/pterodactyl/public/themes/pterodactyl/css/pterodactyl.css";
|
2023-03-17 10:47:28 -04:00
|
|
|
sed -i "s!@import 'checkbox.css';!@import 'checkbox.css';\n@import url(/assets/extensions/blueprint/blueprint.style.css);!g" /var/www/pterodactyl/public/themes/pterodactyl/css/pterodactyl.css;
|
2023-03-06 13:11:53 -05:00
|
|
|
|
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_bright "php artisan view:clear";
|
2023-03-06 13:11:53 -05:00
|
|
|
php artisan view:clear > /dev/null;
|
2023-03-08 12:35:54 -05:00
|
|
|
|
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_bright "php artisan config:clear";
|
2023-03-06 13:11:53 -05:00
|
|
|
php artisan config:clear > /dev/null;
|
|
|
|
|
2023-03-08 12:35:54 -05:00
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_bright "chown -R www-data:www-data /var/www/pterodactyl/*";
|
2023-03-06 13:11:53 -05:00
|
|
|
chown -R www-data:www-data /var/www/pterodactyl/* > /dev/null;
|
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
clr_bright "chown -R www-data:www-data /var/www/pterodactyl/.*";
|
2023-03-19 15:20:01 -04:00
|
|
|
chown -R www-data:www-data /var/www/pterodactyl/.* > /dev/null;
|
|
|
|
|
2023-03-03 11:00:03 -05:00
|
|
|
dbAdd "blueprint.setupFinished";
|
2023-03-03 10:52:29 -05:00
|
|
|
fi;
|
2023-03-19 15:20:01 -04:00
|
|
|
fi;
|
|
|
|
|
2023-03-19 16:02:29 -04:00
|
|
|
touch /usr/local/bin/blueprint > /dev/null;
|
|
|
|
echo -e "#!/bin/bash\nbash /var/www/pterodactyl/blueprint.sh -bash \$@;" > /usr/local/bin/blueprint;
|
|
|
|
chmod u+x /var/www/pterodactyl/blueprint.sh > /dev/null;
|
|
|
|
chmod u+x /usr/local/bin/blueprint > /dev/null;
|
|
|
|
|
2023-03-19 15:20:01 -04:00
|
|
|
if [[ $2 == "help" ]]; then
|
|
|
|
echo -e "";
|
2023-03-18 06:24:16 -04:00
|
|
|
fi;
|