Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,13 @@ configure_ci_runner() {
fi
}

configure_sudoer() {
if [[ $SUDOER == true ]]; then
sudo adduser ${GITLAB_CI_MULTI_RUNNER_USER} sudo
sudo echo "${GITLAB_CI_MULTI_RUNNER_USER} ALL=NOPASSWD: ALL" > /etc/sudoers.d/${GITLAB_CI_MULTI_RUNNER_USER}
fi
}

# allow arguments to be passed to gitlab-ci-multi-runner
if [[ ${1:0:1} = '-' ]]; then
EXTRA_ARGS="$@"
Expand All @@ -75,6 +82,7 @@ if [[ -z ${1} ]]; then
update_ca_certificates
generate_ssh_deploy_keys
grant_access_to_docker_socket
configure_sudoer
configure_ci_runner

start-stop-daemon --start \
Expand Down