Add DOCKER_DRONE_EXTRA_ARGS config parameter and try restart=false.

This commit is contained in:
Manuel Friedli 2020-09-26 00:25:06 +02:00
parent bfbd5086c8
commit d78b791254
3 changed files with 9 additions and 4 deletions

View file

@ -30,5 +30,8 @@ DRONE_SERVER_PROTO="https"
# DRONE_GIT_ALWAYS_AUTH=true
# Required string value configures ports to publish for docker: space-separated
# list of <hostport>:<containerport> tuples
# list of <hostport>:<containerport> tuples.
DOCKER_PUBLISH="8080:80 8443:443"
# Optional string value of extra args passed verbatim to the docker command.
DOCKER_DRONE_EXTRA_ARGS=""

View file

@ -18,10 +18,12 @@ for p in ${DOCKER_PUBLISH} ; do
docker_args="${docker_args} --publish=${p}"
done
docker_args="${docker_args} ${DOCKER_DRONE_EXTRA_ARGS}"
docker run \
--volume=/var/lib/drone:/data \
${docker_args} \
--restart=always \
--detach=true \
--detach=false \
--name=drone \
drone/drone:<VERSION>