From 22aa9c86a70a729c631185cb5e12bfd316f39ab2 Mon Sep 17 00:00:00 2001 From: Viktor Barzin Date: Sun, 1 Feb 2026 21:53:18 +0000 Subject: [PATCH] update drone.yaml to build on push --- .drone.yml | 36 +++++++++++++----------------------- 1 file changed, 13 insertions(+), 23 deletions(-) diff --git a/.drone.yml b/.drone.yml index f4e62cb..456e6f1 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,66 +1,56 @@ kind: pipeline type: kubernetes name: frontend -timeout: 30m trigger: - event: - - push - - cron branch: - - master + - master + event: + - push steps: - name: Build frontend image image: plugins/docker settings: - username: "viktorbarzin" + username: viktorbarzin password: from_secret: dockerhub-token repo: viktorbarzin/immoweb dockerfile: crawler/frontend/Dockerfile context: crawler/frontend - cache_from: "viktorbarzin/immoweb:latest" auto_tag: true + - name: Update deployment image: alpine commands: - - "apk add curl" + - apk add curl - 'curl -X PATCH https://kubernetes:6443/apis/apps/v1/namespaces/realestate-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: pipeline type: kubernetes name: api -timeout: 30m trigger: - event: - - push - - cron branch: - - master + - master + event: + - push steps: - - name: Build backend API image + - name: Build API image image: plugins/docker settings: - username: "viktorbarzin" + username: viktorbarzin password: from_secret: dockerhub-token repo: viktorbarzin/realestatecrawler dockerfile: crawler/Dockerfile context: crawler/ - cache_from: "viktorbarzin/realestatecrawler:latest" auto_tag: true + - name: Update deployment image: alpine commands: - - "apk add curl" + - apk add curl - 'curl -X PATCH https://kubernetes:6443/apis/apps/v1/namespaces/realestate-crawler/deployments/realestate-crawler-api -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' -# Sun Feb 1 08:29:56 PM UTC 2026 -# Webhook test Sun Feb 1 08:45:52 PM UTC 2026 -# 1769978870 -# test 1769979073 -# final test 1769979293 -# no secret test 1769979359