Use static version of Authelia in suites when in CI.

This is to avoid the multiple reloads due to the frontend modules
being installed at the startup of the suite and randomly preventing
Authelia from starting.
This commit is contained in:
Clement Michaud 2019-12-09 07:38:20 +01:00 committed by Clément Michaud
parent 26798cdf3a
commit c3569d9bd0
3 changed files with 14 additions and 5 deletions

View File

@ -9,6 +9,7 @@ fi
export USER_ID=$(id -u)
export GROUP_ID=$(id -g)
export CI=false
echo "[BOOTSTRAP] Checking if Go is installed..."

View File

@ -15,6 +15,7 @@ services:
- "${GOPATH}:/go"
environment:
- ENVIRONMENT=dev
- CI=${CI}
networks:
authelianet:
ipv4_address: 192.168.240.50

View File

@ -2,10 +2,17 @@
set -x
go get github.com/cespare/reflex
if [ "$CI" == "true" ];
then
echo "Use static version of Authelia"
/resources/run.sh
else
echo "Use hot reloaded version of Authelia"
go get github.com/cespare/reflex
# Sleep 10 seconds to wait the end of npm install updating web directory
# and making reflex reload multiple times.
sleep 10
# Sleep 10 seconds to wait the end of npm install updating web directory
# and making reflex reload multiple times.
sleep 10
reflex -c /resources/reflex.conf
reflex -c /resources/reflex.conf
fi