feat(jvb): autoscaler sidecar shutdown hook on finish (#1906)
parent
b0675c0e24
commit
e7cb0f4bca
@ -1,8 +1,11 @@ |
|||||||
#!/usr/bin/with-contenv bash |
#!/usr/bin/with-contenv bash |
||||||
# notify the sidecar of imminent shutdown |
|
||||||
PORT=${AUTOSCALER_SIDECAR_PORT:-6000} |
if [ -n "$AUTOSCALER_URL" ]; then |
||||||
curl -d '{}' -v 0:$PORT/hook/v1/shutdown |
# notify the sidecar of imminent shutdown |
||||||
sleep 10 |
PORT=${AUTOSCALER_SIDECAR_PORT:-6000} |
||||||
|
curl -d '{}' -v 0:$PORT/hook/v1/shutdown |
||||||
|
sleep 10 |
||||||
|
fi |
||||||
|
|
||||||
# shutdown everything |
# shutdown everything |
||||||
s6-svscanctl -t /var/run/s6/services |
s6-svscanctl -t /var/run/s6/services |
||||||
|
Loading…
Reference in new issue