add drone ci config
This commit is contained in:
parent
5fb8216b88
commit
0bee75fd71
1 changed files with 23 additions and 0 deletions
23
.drone.yml
Normal file
23
.drone.yml
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
kind: pipeline
|
||||
type: kubernetes
|
||||
name: default
|
||||
|
||||
steps:
|
||||
- name: Build frontend image
|
||||
image: plugins/docker
|
||||
settings:
|
||||
username: "viktorbarzin"
|
||||
password:
|
||||
from_secret: dockerhub-token
|
||||
repo: viktorbarzin/blog
|
||||
dockerfile: crawler/frontend/Dockerfile
|
||||
auto_tag: true
|
||||
- name: Update deployment
|
||||
image: alpine
|
||||
commands:
|
||||
- "apk add curl"
|
||||
- 'curl -X PATCH https://kubernetes:6443/apis/apps/v1/namespaces/real-estate-crawler/deployments/realestate-crawler-ui -H "Authorization:Bearer $(cat /var/run/secrets/kubernetes.io/serviceaccount/token)" -H "Content-Type:application/strategic-merge-patch+json" -k -d ''{"spec": {"template": {"metadata": { "annotations": {"kubectl.kubernetes.io/restartedAt": "''$(date +%Y-%m-%dT%TZ)''" }}}}}'' | head'
|
||||
# ---
|
||||
# kind: secret
|
||||
# name: dockerhub_password
|
||||
# data: ZB3OHrGwCBy4pVQZv+fiPWN1mUeegBnB2kh+2O5nbLQmoU2ls6bdXB70NiRcbVrE
|
||||
Loading…
Add table
Add a link
Reference in a new issue