Compare commits

..

No commits in common. "deploy-at-home" and "master" have entirely different histories.

11 changed files with 500 additions and 690 deletions

View File

@ -1,6 +1 @@
docker build drone -t ${REGISTRY_DOMAIN}:${REGISTRY_PORT}/${ROOT}/${NAME}/drone \ echo 'nothing to build'
--build-arg REGISTRY= \
&& docker build drone-runner -t ${REGISTRY_DOMAIN}:${REGISTRY_PORT}/${ROOT}/${NAME}/drone-runner \
--build-arg REGISTRY= \

View File

@ -1,5 +1,5 @@
export LOCAL_DOCKER_REGISTRY=${REGISTRY_DOMAIN}:${REGISTRY_PORT}/${ROOT}/${NAME}/ export LOCAL_DOCKER_REGISTRY=${REGISTRY_DOMAIN}:${REGISTRY_PORT}/${ROOT}/${NAME}/
docker stack rm drone \ docker stack rm drone \
&& echo 'sleeping...zzz' \ && echo 'sleeping...zzz' \
&& sleep 30 \ && sleep 60 \
&& docker stack deploy -c docker-compose.yml drone --with-registry-auth && docker stack deploy -c docker-compose.yml drone --with-registry-auth

File diff suppressed because it is too large Load Diff

View File

@ -1,7 +1,6 @@
# drone # drone
## secrets ## secrets
* drone-convert-secret
* drone-gitea-client-id * drone-gitea-client-id
* drone-gitea-client-secret * drone-gitea-client-secret
* drone-gitea-server * drone-gitea-server
@ -9,6 +8,5 @@
* drone-server-host * drone-server-host
* local-docker-registry * local-docker-registry
* registry-password * registry-password
* local-ip

View File

@ -4,11 +4,11 @@ services:
# drone server application # drone server application
deploy: deploy:
placement: placement:
constraints: [node.labels.com.sigyl.drone == yes] constraints: [node.labels.com.sigyl.git-stack == yes]
replicas: 1 replicas: 1
restart_policy: restart_policy:
condition: any condition: any
image: ${LOCAL_DOCKER_REGISTRY}drone image: ${LOCAL_DOCKER_REGISTRY}drone/drone:2.4.0
volumes: volumes:
- drone-5:/var/lib/drone - drone-5:/var/lib/drone
- drone-data-5:/data - drone-data-5:/data
@ -26,20 +26,18 @@ services:
- DRONE_USER_CREATE=username:giles,admin:true - DRONE_USER_CREATE=username:giles,admin:true
- DRONE_AGENTS_ENABLED=true - DRONE_AGENTS_ENABLED=true
- DRONE_JSONNET_ENABLED=true - DRONE_JSONNET_ENABLED=true
ports:
- 81:8080
networks: networks:
- appnet - appnet
- externalnet - externalnet
drone-runner: drone-docker-runner:
# drone runner performs builds # drone runner performs builds
deploy: deploy:
placement: placement:
constraints: [node.labels.com.sigyl.drone-runner == yes] constraints: [node.labels.com.sigyl.git-stack == yes]
replicas: 1 replicas: 1
restart_policy: restart_policy:
condition: any condition: any
image: ${LOCAL_DOCKER_REGISTRY}drone-runner image: ${LOCAL_DOCKER_REGISTRY}drone/drone-runner-docker:1.6.3
volumes: volumes:
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
environment: environment:
@ -48,7 +46,7 @@ services:
- DRONE_RPC_SECRET=${DRONE_RPC_SECRET} - DRONE_RPC_SECRET=${DRONE_RPC_SECRET}
- DRONE_RUNNER_CAPACITY=8 - DRONE_RUNNER_CAPACITY=8
- DRONE_RUNNER_NAME="docker-runner" - DRONE_RUNNER_NAME="docker-runner"
- DRONE_RUNNER_ENVIRON=SCHEME:$SCHEME,DOMAIN:$DOMAIN,REGISTRY_DOMAIN:$REGISTRY_DOMAIN,REGISTRY_PORT:$REGISTRY_PORT,REGISTRY_PASSWORD:$REGISTRY_PASSWORD,SSH_HOST:$SSH_HOST,SSH_PORT:$SSH_PORT,SSH_USERNAME:$SSH_USERNAME,SSH_KEY:$SSH_KEY,SSH_PASSWORD:$SSH_PASSWORD - DRONE_RUNNER_ENVIRON=SCHEME:$SCHEME,DOMAIN:$DOMAIN,REGISTRY_DOMAIN:$REGISTRY_DOMAIN,REGISTRY_PORT:$REGISTRY_PORT,REGISTRY_PASSWORD:$REGISTRY_PASSWORD,SSH_HOST:$SSH_HOST,SSH_PORT:$SSH_PORT,SSH_USERNAME:$SSH_USERNAME,SSH_KEY:$SSH_KEY
networks: networks:
- appnet - appnet
volumes: volumes:
@ -58,9 +56,7 @@ volumes:
networks: networks:
appnet: appnet:
driver: overlay driver: overlay
attachable: true
#external: true #external: true
externalnet: externalnet:
driver: overlay driver: overlay
external: true external: true
name: externalnet

View File

@ -1,17 +0,0 @@
FROM ${REGISTRY}drone/drone-runner-docker:1.6.3
# USER root
#RUN apk update
#RUN apk add gettext
#COPY hosts.template /etc/hosts.template
#COPY run.sh /
#ENTRYPOINT sh /run.sh
#CMD ["sh", "/run.sh"]
#COPY config.production.json.template /var/lib/ghost/
#COPY --from=git /themes/ /var/lib/ghost/content/themes/
#COPY post.hbs /hbs/
#COPY run.sh /
#CMD ["sh", "/run.sh"]

View File

@ -1,2 +0,0 @@
${GIT_IP} ${GIT_DOMAIN}

View File

@ -1,2 +0,0 @@
envsubst < /etc/hosts.template >> /etc/hosts
/bin/drone-runner-docker

View File

@ -1,17 +0,0 @@
FROM ${REGISTRY}drone/drone:2.12.0
# USER root
#RUN apk update
#RUN apk add gettext
#COPY hosts.template /etc/hosts.template
#COPY run.sh /
#ENTRYPOINT sh /run.sh
#CMD ["sh", "/run.sh"]
#COPY config.production.json.template /var/lib/ghost/
#COPY --from=git /themes/ /var/lib/ghost/content/themes/
#COPY post.hbs /hbs/
#COPY run.sh /
#CMD ["sh", "/run.sh"]

View File

@ -1,2 +0,0 @@
${GIT_IP} ${GIT_DOMAIN}

View File

@ -1,2 +0,0 @@
envsubst < /etc/hosts.template >> /etc/hosts
drone-server