mirror of
https://github.com/eduardogsilva/routerfleet.git
synced 2025-07-21 19:34:26 +02:00
Fixed issue with non standard http/https ports
This commit is contained in:
parent
89ec66b4ad
commit
c7f1dd2e9e
4 changed files with 7 additions and 5 deletions
|
@ -26,7 +26,7 @@ services:
|
|||
- POSTGRES_USER=${POSTGRES_USER}
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
- TZ=${TIMEZONE}
|
||||
- COMPOSE_VERSION=02c
|
||||
- COMPOSE_VERSION=02d
|
||||
- COMPOSE_TYPE=with-postgres
|
||||
|
||||
volumes:
|
||||
|
|
|
@ -13,7 +13,7 @@ services:
|
|||
- POSTGRES_USER=${POSTGRES_USER}
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
- TZ=${TIMEZONE}
|
||||
- COMPOSE_VERSION=02c
|
||||
- COMPOSE_VERSION=02d
|
||||
- COMPOSE_TYPE=no-postgres
|
||||
volumes:
|
||||
- sqlite_volume:/var/lib/routerfleet_sqlite/
|
||||
|
|
|
@ -25,7 +25,7 @@ services:
|
|||
- POSTGRES_USER=${POSTGRES_USER}
|
||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||
- TZ=${TIMEZONE}
|
||||
- COMPOSE_VERSION=02c
|
||||
- COMPOSE_VERSION=02d
|
||||
- COMPOSE_TYPE=with-postgres
|
||||
volumes:
|
||||
- sqlite_volume:/var/lib/routerfleet_sqlite/
|
||||
|
|
|
@ -3,7 +3,7 @@ PRODUCTION_SETTINGS_FILE="/app/routerfleet/production_settings.py"
|
|||
|
||||
set -e
|
||||
|
||||
if [[ "$COMPOSE_VERSION" != "02c" ]]; then
|
||||
if [[ "$COMPOSE_VERSION" != "02d" ]]; then
|
||||
echo "ERROR: Please upgrade your docker compose file. Exiting."
|
||||
exit 1
|
||||
fi
|
||||
|
@ -66,9 +66,11 @@ if [[ "${DEBUG_MODE,,}" == "true" ]]; then
|
|||
DEBUG_VALUE="True"
|
||||
fi
|
||||
|
||||
SERVER_HOSTNAME=$(echo $SERVER_ADDRESS | cut -d ':' -f 1)
|
||||
|
||||
cat > $PRODUCTION_SETTINGS_FILE <<EOL
|
||||
DEBUG = $DEBUG_VALUE
|
||||
ALLOWED_HOSTS = ['routerfleet', '$SERVER_ADDRESS']
|
||||
ALLOWED_HOSTS = ['routerfleet', '$SERVER_HOSTNAME']
|
||||
CSRF_TRUSTED_ORIGINS = ['http://routerfleet', 'https://$SERVER_ADDRESS', 'http://$SERVER_ADDRESS']
|
||||
SECRET_KEY = '$(openssl rand -base64 32)'
|
||||
$DATABASES_CONFIG
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue