adjust install scripts | allow user to enter trusted proxies value
This commit is contained in:
parent
efb51d03b0
commit
6a2f0ba6fe
3 changed files with 13 additions and 10 deletions
|
@ -1,5 +1,4 @@
|
|||
# pterodactyl-panel-docker
|
||||
[![GitHub release](https://img.shields.io/github/release/TehTotalPwnage/pterodactyl-panel-docker.svg?style=for-the-badge)](https://github.com/TehTotalPwnage/pterodactyl-panel-docker/releases)
|
||||
# Pterodactyl panel Docker container
|
||||
> Docker Compose configuration for the [Pterodactyl Panel](https://github.com/Pterodactyl/Panel).
|
||||
|
||||
Pterodactyl is an open-source control panel used for hosting numerous game-related
|
||||
|
|
|
@ -12,13 +12,20 @@ fi
|
|||
echo "Are you sure you want to continue the install script? (Y/n)"
|
||||
read -n1 run
|
||||
|
||||
if [ "$run" = "y" ] || [ "$run" = "Y" ]; then
|
||||
if [ "$run" = "y" ] || [ "$run" = "Y" ] || [ "$run" = "" ]; then
|
||||
echo "Running install script."
|
||||
echo "Waiting 15 seconds for MariaDB to be ready."
|
||||
sleep 15
|
||||
|
||||
echo "Adding additional parameters to .env file."
|
||||
printf "\n\nTRUSTED_PROXIES=*" >> .env
|
||||
echo "Configure trusted proxies (this will enable reverse proxy functionality)? (Y/n)"
|
||||
read -n1 configureTP
|
||||
if [ "$configureTP" = "y" ] || [ "$configureTP" = "Y" ] || [ "$run" = "" ]; then
|
||||
echo "Please enter a value (comma separated list of allowed IPs, * to allow all) for TRUSTED_PROXIES: [*]"
|
||||
read -n1 configureTPval
|
||||
if [ "$configureTPval" = "" ]; then
|
||||
configureTPval="*"
|
||||
printf "\n\nTRUSTED_PROXIES=$configureTPval" >> .env
|
||||
fi
|
||||
php artisan key:generate --force
|
||||
|
||||
echo "Running configuration scripts."
|
||||
|
|
|
@ -1,18 +1,15 @@
|
|||
#!/bin/ash
|
||||
|
||||
##
|
||||
# This is an install script to quickly upgrade Pterodactyl Panel. Before running,
|
||||
# please BACK UP any important data!
|
||||
##
|
||||
if [ "$(whoami)" != "pterodactyl" ]; then
|
||||
echo "Rerunning script as webserver user."
|
||||
exec su -c /usr/local/bin/upgrade pterodactyl
|
||||
fi
|
||||
|
||||
echo "!!! PLEASE BACKUP ANY IMPORTANT DATA BEFORE UPGRADING !!!"
|
||||
echo "Are you sure you want to continue the upgrade script? (Y/n)"
|
||||
read -n1 run
|
||||
|
||||
if [ "$run" = "Y" ]; then
|
||||
if [ "$run" = "y" ] || [ "$run" = "Y" ]; then
|
||||
echo "Running upgrade script."
|
||||
php artisan down
|
||||
|
||||
|
|
Reference in a new issue