Add promotions in drone.io"
continuous-integration/drone/push Build is failing Details

test
Dan 2023-08-01 11:10:09 -06:00
parent 9693fb92d5
commit db35563e6f
1 changed files with 38 additions and 5 deletions

View File

@ -1,16 +1,43 @@
kind: pipeline
type: docker
name: default
name: build
steps:
- name: node
image: docker
commands:
- docker build --tag ofb_api .
---
kind: pipeline
type: docker
name: deploy_test
steps:
- name: node
image: docker
volumes:
- name: docker_sock
path: /var/run/docker.sock
commands:
- docker rm -f ofb_api_test || true
- docker run --name ofb_api_test --network=proxy --restart always -d -e ASPNETCORE_ENVIRONMENT="Development" -e ConnectionStrings__OFBContext="server=mysql;database=ofb_missionary;user=admin_ofbbutte;password=87hjdusiodksyeunsjkdis7;" ofb_api_test
- docker network connect mysql ofb_api_test
volumes:
- name: docker_sock
host:
path: /var/run/docker.sock
---
kind: pipeline
type: docker
name: deploy_prod
steps:
- name: node
image: docker
volumes:
- name: docker_sock
path: /var/run/docker.sock
secrets:
- DB_PASS
commands:
- docker build --tag ofb_api .
- docker rm -f ofb_api || true
- docker run --name ofb_api --network=proxy --restart always -d -e ASPNETCORE_ENVIRONMENT="Production" -e ConnectionStrings__OFBContext="server=mysql;database=ofb_missionary;user=admin_ofbbutte;password=87hjdusiodksyeunsjkdis7;" ofb_api
- docker network connect mysql ofb_api
@ -19,3 +46,9 @@ volumes:
- name: docker_sock
host:
path: /var/run/docker.sock
trigger:
event:
- promote
target:
- production