.
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Giles Bradshaw 2020-04-03 13:50:11 +01:00
parent 34368df723
commit 1887788171
2 changed files with 119 additions and 15 deletions

View File

@ -3,9 +3,6 @@
kind: pipeline
type: docker
name: default
when:
branch:
- master
clone:
# skip_verify: true
@ -15,7 +12,7 @@ steps:
- name: wait
when:
branch:
- master
- home-deploy
image: docker:dind
volumes:
- name: dockersock
@ -23,10 +20,111 @@ steps:
commands:
- sleep 60
- name: build-postgres
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd guacamole-postgresql
- docker build . -t $${LOCAL_DOCKER_REGISTRY}guacamole-postgresql
- docker push $${LOCAL_DOCKER_REGISTRY}guacamole-postgresql
- name: build-ngrok
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd ngrok2
- docker build . -t $${LOCAL_DOCKER_REGISTRY}ngrok-gitea
- docker push $${LOCAL_DOCKER_REGISTRY}ngrok-gitea
- name: build-letsencrypt-nginx
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd letsencrypt-nginx
- docker build . -t $${LOCAL_DOCKER_REGISTRY}letsencrypt-nginx
- docker push $${LOCAL_DOCKER_REGISTRY}letsencrypt-nginx
- name: build-letsencrypt-blog
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd letsencrypt-nginx
- sh build.sh blog $${LOCAL_DOCKER_REGISTRY}
- name: build-letsencrypt-drone
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd letsencrypt-nginx
- sh build.sh drone $${LOCAL_DOCKER_REGISTRY}
- name: build-letsencrypt-git
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd letsencrypt-nginx
- sh build.sh git $${LOCAL_DOCKER_REGISTRY}
- name: build-letsencrypt-remote
when:
branch:
- home-deploy
image: docker:dind
volumes:
- name: dockersock
path: /var/run
environment:
LOCAL_DOCKER_REGISTRY:
from_secret: local-docker-registry
commands:
- cd letsencrypt-nginx
- sh build.sh remote $${LOCAL_DOCKER_REGISTRY}
- name: build-letsencrypt-chat
when:
branch:
- master
- home-deploy
image: docker:dind
volumes:
- name: dockersock
@ -40,7 +138,7 @@ steps:
- name: scp files
when:
branch:
- master
- home-deploy
image: appleboy/drone-scp
settings:
host:
@ -58,7 +156,7 @@ steps:
- name: deploy
when:
branch:
- master
- home-deploy
image: appleboy/drone-ssh
environment:
DRONE_RPC_SECRET:
@ -117,11 +215,17 @@ steps:
- export CHAT_DOMAIN=$CHAT_DOMAIN
- export REMOTE_DOMAIN=$REMOTE_DOMAIN
- export BLOG_DOMAIN=$BLOG_DOMAIN
- docker pull $${LOCAL_DOCKER_REGISTRY}letsencrypt-git
- docker pull $${LOCAL_DOCKER_REGISTRY}letsencrypt-chat
- docker pull $${LOCAL_DOCKER_REGISTRY}letsencrypt-remote
- docker pull $${LOCAL_DOCKER_REGISTRY}letsencrypt-blog
- docker pull $${LOCAL_DOCKER_REGISTRY}letsencrypt-drone
- docker network prune -f
- cd /home/$SSH_USER/gitea-drone-stack
- docker stack rm gitea
- sleep 60
- docker stack deploy -c docker-compose.yml gitea
- docker stack deploy -c docker-compose-home.yml gitea
#- sleep 300
services:

View File

@ -7,7 +7,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/letsencrypt-chat
image: ${LOCAL_DOCKER_REGISTRY}letsencrypt-chat
environment:
- SERVER_NAME=${CHAT_DOMAIN}
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
@ -23,7 +23,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/letsencrypt-remote
image: ${LOCAL_DOCKER_REGISTRY}letsencrypt-remote
environment:
- SERVER_NAME=${REMOTE_DOMAIN}
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
@ -41,7 +41,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/letsencrypt-git
image: ${LOCAL_DOCKER_REGISTRY}letsencrypt-git
environment:
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
- SERVER_NAME=${GIT_DOMAIN}
@ -59,7 +59,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/letsencrypt-drone
image: ${LOCAL_DOCKER_REGISTRY}letsencrypt-drone
environment:
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
- SERVER_NAME=${DRONE_DOMAIN}
@ -97,7 +97,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/ngrok-gitea
image: ${LOCAL_DOCKER_REGISTRY}ngrok-gitea
ports:
- "4040:4040"
volumes:
@ -216,7 +216,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/letsencrypt-blog
image: ${LOCAL_DOCKER_REGISTRY}letsencrypt-blog
environment:
- CERTBOT_EMAIL=${CERTBOT_EMAIL}
- SERVER_NAME=${BLOG_DOMAIN}
@ -251,7 +251,7 @@ services:
replicas: 1
restart_policy:
condition: any
image: ${LOCAL_DOCKER_REGISTRY}/guacamole-postgresql:latest
image: ${LOCAL_DOCKER_REGISTRY}guacamole-postgresql:latest
environment:
POSTGRES_PASSWORD: guacroot
POSTGRES_DB: guacamole_db