From d99e3d7f75d7a6463ed9ea8def5d573e30ebd717 Mon Sep 17 00:00:00 2001 From: Benjamin Salzberg Date: Wed, 1 May 2024 02:01:20 +0000 Subject: [PATCH] configure will now only handle the nginx reverse proxy and will default to 8080 --- configure-instance.sh | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/configure-instance.sh b/configure-instance.sh index 649a687..e701c36 100755 --- a/configure-instance.sh +++ b/configure-instance.sh @@ -3,7 +3,14 @@ echo "Enter a hostname for the Frontend (eg: piped.kavin.rocks):" && read -r fro echo "Enter a hostname for the Backend (eg: pipedapi.kavin.rocks):" && read -r backend echo "Enter a hostname for the Proxy (eg: pipedproxy.kavin.rocks):" && read -r proxy echo "Enter the reverse proxy you would like to use (either caddy or nginx):" && read -r reverseproxy -echo "Enter a port to use for the reverse proxy:" && read -r port +port=8080 # Define default port +if [[ $reverseproxy = "nginx" ]]; then # if the nginx reverse proxy is used, we want to get a custom port + echo "Enter a port to use for the reverse proxy:" && read -r port +fi +integerregex='^[0-9]+$' +if ! [[ $port =~ $integerregex ]] ; then # ensure that the port is an integer. If it is not set it to the default. + port=8080 +fi rm -rf config/ rm -f docker-compose.yml