Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate drone-builder from Drone to DK CI/CD #177

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 16 additions & 44 deletions .drone.yml
Original file line number Diff line number Diff line change
@@ -1,53 +1,25 @@
kind: pipeline
type: kubernetes
name: Deployment Stable

steps:
- name: docker-build
image: docker
pull: if-not-exists
environment:
DOCKER_REGISTRY: 558830342743.dkr.ecr.us-east-1.amazonaws.com
commands:
- docker build --network=host -t $$DOCKER_REGISTRY/healthcheck/webtests/checkout:latest -f ./dockerfiles/stable/Dockerfile .
volumes:
- name: dockersock
path: /var/run
- name: publish
image: 053131491888.dkr.ecr.us-east-1.amazonaws.com/vtex/drone-builder:latest
pull: always
when:
ref:
include:
- refs/tags/**
exclude:
- refs/tags/*-*
environment:
AWS_DEFAULT_REGION: us-east-1
AWS_ACCESS_KEY_ID:
from_secret: 558830342743_AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY:
from_secret: 558830342743_AWS_SECRET_ACCESS_KEY
GIT_TOKEN:
from_secret: GIT_TOKEN
GIT_USER_NAME: ${DRONE_COMMIT_AUTHOR}
GIT_USER_EMAIL: ${DRONE_COMMIT_AUTHOR_EMAIL}
DOCKER_REGISTRY: 558830342743.dkr.ecr.us-east-1.amazonaws.com
ENVIRONMENT: stable
CICD_FORCE_NO_BUMP: true
CICD_K8S_CLUSTER: EKS-Robots
commands:
- python3 /app/toolbelt/main.py
volumes:
- name: dockersock
path: /var/run

- name: docker-build
image: docker
pull: if-not-exists
environment:
DOCKER_REGISTRY: 558830342743.dkr.ecr.us-east-1.amazonaws.com
commands:
- >-
docker build --network=host -t
$$DOCKER_REGISTRY/healthcheck/webtests/checkout:latest -f
./dockerfiles/stable/Dockerfile .
volumes:
- name: dockersock
path: /var/run
trigger:
event:
- push
- tag

volumes:
- name: dockersock
host:
path: /var/run/
- name: dockersock
host:
path: /var/run/
20 changes: 20 additions & 0 deletions .vtex/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
- acronym: checkout-ui-tests
build:
pipelines:
- name: drone-builder-v1
parameters:
awsAccountId: "558830342743"
awsRegion: us-east-1
cicdForceNoBump: "true"
cicdK8sCluster: EKS-Robots
environment: stable
runtime:
architecture: amd64
when:
- event: push
source: branch
- event: push
source: tag
provider: dkcicd
description: Deploy with drone-builder
name: checkout-ui-tests