You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
41 lines
906 B
41 lines
906 B
--- |
|
kind: pipeline |
|
name: default |
|
|
|
steps: |
|
- name: build blenderbot |
|
image: plugins/docker |
|
settings: |
|
username: |
|
from_secret: docker_username |
|
password: |
|
from_secret: docker_password |
|
repo: daveplsno/blenderbot |
|
tags: |
|
- latest |
|
- '${DRONE_COMMIT_SHA:0:8}' |
|
|
|
- name: deploy blenderbot to swarm |
|
image: docker:dind |
|
environment: |
|
DEPLOY_ENV: |
|
from_secret: DEPLOY_ENV |
|
volumes: |
|
- name: dockersock |
|
path: /var/run/docker.sock |
|
commands: |
|
- export $DEPLOY_ENV |
|
- export imageTag='${DRONE_COMMIT_SHA:0:8}' |
|
- docker stack deploy -c ./swarm/docker-compose.blenderbot.yml blenderbot |
|
- docker service update --force --update-parallelism 1 --update-delay 30s blenderbot_bot |
|
|
|
volumes: |
|
- name: dockersock |
|
host: |
|
path: /var/run/docker.sock |
|
|
|
trigger: |
|
branch: |
|
- master |
|
event: |
|
- push
|
|
|