Commit 10e7ad99 authored by Michał "rysiek" Woźniak's avatar Michał "rysiek" Woźniak
Browse files

entrypoint: exit with error if runner fails to register

parent e3b8bae2
......@@ -35,6 +35,10 @@ if [[ ! -e ${CONFIG_FILE} ]]; then
# register the runner
su gitlab-runner -c \
"gitlab-runner register --non-interactive --config '${CONFIG_FILE}' --url '${CI_SERVER_URL}' --registration-token '${RUNNER_TOKEN}' --description '${RUNNER_DESCRIPTION}' --executor '${RUNNER_EXECUTOR}'"
if [ $? != 0 ]; then
echo " ERROR: failed to register the runner!"
exit 2
echo " ERROR: no config file and no configuration vars!"
exit 1
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment