mirror of
https://github.com/actions/actions-runner-controller.git
synced 2025-12-10 19:50:30 +00:00
Use dumb-init to handle signal properly
This commit is contained in:
@@ -9,6 +9,8 @@ RUN apt update \
|
||||
&& tar zxvf docker.tgz \
|
||||
&& install -o root -g root -m 755 docker/docker /usr/local/bin/docker \
|
||||
&& rm -rf docker docker.tgz \
|
||||
&& curl -L -o /usr/local/bin/dumb-init https://github.com/Yelp/dumb-init/releases/download/v1.2.2/dumb-init_1.2.2_amd64 \
|
||||
&& chmod +x /usr/local/bin/dumb-init \
|
||||
&& adduser --disabled-password --gecos "" --uid 1000 runner
|
||||
|
||||
RUN mkdir -p /runner \
|
||||
@@ -21,4 +23,5 @@ RUN mkdir -p /runner \
|
||||
COPY entrypoint.sh /runner
|
||||
|
||||
USER runner:runner
|
||||
ENTRYPOINT ["/runner/entrypoint.sh"]
|
||||
ENTRYPOINT ["/usr/local/bin/dumb-init", "--"]
|
||||
CMD ["/runner/entrypoint.sh"]
|
||||
|
||||
@@ -17,4 +17,4 @@ fi
|
||||
|
||||
cd /runner
|
||||
./config.sh --unattended --replace --name "${RUNNER_NAME}" --url "https://github.com/${RUNNER_REPO}" --token "${RUNNER_TOKEN}"
|
||||
./run.sh --once
|
||||
exec ./run.sh --once
|
||||
|
||||
Reference in New Issue
Block a user