Skip to content

Commit

Permalink
http
Browse files Browse the repository at this point in the history
  • Loading branch information
sinamics committed Dec 3, 2023
1 parent 98e21b5 commit 93b88fa
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions install.ztnet/bash/ztnet.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,14 @@ printf "==> " >&2
read input_ip < /dev/tty

# Use the default local_ip if the user pressed Enter without typing anything
if [[ -z $input_ip ]]; then
server_ip=$local_ip
else
server_ip=$input_ip
server_ip=${input_ip:-$local_ip}

# Check if http:// is already included in the server_ip
if [[ $server_ip != http://* ]]; then
server_ip="http://${server_ip}"
fi


POSTGRES_PASSWORD="postgres"

# Install PostgreSQL
Expand Down Expand Up @@ -206,7 +208,7 @@ DATABASE_URL="postgresql://postgres:[email protected]:5432/ztnet?sche
ZT_ADDR=
ZT_SECRET=
NEXT_PUBLIC_SITE_NAME="ZTnet"
NEXTAUTH_URL="http://${server_ip:-localhost}:3000"
NEXTAUTH_URL="${server_ip}:3000"
NEXT_PUBLIC_APP_VERSION="${CUSTOM_VERSION:-$latestTag}"

# Set or update environment variables
Expand Down

0 comments on commit 93b88fa

Please sign in to comment.