Allow preset env variable for django secret
The source command fails if /run/secrets/django does not exist. This is however not important if DJANGO_SECRET_KEY is already set. This is checked in the next step
This commit is contained in:
parent
7e67e0db12
commit
11d7f7b888
@ -3,7 +3,7 @@
|
|||||||
set -e
|
set -e
|
||||||
|
|
||||||
# Set DJANGO_SECRET_KEY variable
|
# Set DJANGO_SECRET_KEY variable
|
||||||
source /run/secrets/django
|
source /run/secrets/django || true
|
||||||
[[ -n "$DJANGO_SECRET_KEY" ]] || {
|
[[ -n "$DJANGO_SECRET_KEY" ]] || {
|
||||||
echo "ERROR: Django secret key undefined! Cannot continue."
|
echo "ERROR: Django secret key undefined! Cannot continue."
|
||||||
sleep 5
|
sleep 5
|
||||||
|
@ -16,7 +16,7 @@ EOF
|
|||||||
}
|
}
|
||||||
|
|
||||||
# Set DJANGO_SECRET_KEY variable
|
# Set DJANGO_SECRET_KEY variable
|
||||||
source /run/secrets/django
|
source /run/secrets/django || true
|
||||||
[[ -n "$DJANGO_SECRET_KEY" ]] || {
|
[[ -n "$DJANGO_SECRET_KEY" ]] || {
|
||||||
echo "ERROR: Django secret key undefined! Cannot continue."
|
echo "ERROR: Django secret key undefined! Cannot continue."
|
||||||
sleep 5
|
sleep 5
|
||||||
|
Loading…
Reference in New Issue
Block a user