From: Benjamin Diaz Date: Fri, 24 May 2019 15:27:10 +0000 (-0300) Subject: Adds healthcheck to LWUI Dockerfile X-Git-Tag: v6.0.0~10^2 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F46%2F7546%2F2;p=osm%2Fdevops.git Adds healthcheck to LWUI Dockerfile Change-Id: I73cb2379a8fad6b759c0cba4c4b4703c60a1e087 Signed-off-by: Benjamin Diaz --- diff --git a/docker/light-ui/Dockerfile b/docker/light-ui/Dockerfile index 29cbb743..bfcc9e29 100644 --- a/docker/light-ui/Dockerfile +++ b/docker/light-ui/Dockerfile @@ -35,4 +35,7 @@ RUN python manage.py collectstatic --noinput EXPOSE 80 +HEALTHCHECK --start-period=130s --interval=10s --timeout=5s --retries=12 \ + CMD curl --silent --fail localhost:80 || exit 1 + CMD ["supervisord", "-n"] diff --git a/installers/osm_health.sh b/installers/osm_health.sh index 1a9dc7d2..bde1a6a6 100755 --- a/installers/osm_health.sh +++ b/installers/osm_health.sh @@ -1,7 +1,7 @@ #!/bin/sh WAIT_TIME=340 # LCM healthcheck needs 2x(30+140) senconds -SERVICES_WITH_HEALTH="nbi ro zookeeper lcm mon" +SERVICES_WITH_HEALTH="nbi ro zookeeper lcm mon light-ui" NUM_SERVICES_WITH_HEALTH=$(echo $SERVICES_WITH_HEALTH | wc -w) WAIT_FINAL=30