From 851054c617a804f591e40e0468265394a778e410 Mon Sep 17 00:00:00 2001 From: SorsOps <80043879+sorsOps@users.noreply.github.com> Date: Mon, 20 May 2024 12:11:29 +0200 Subject: [PATCH] Add port label tracking and add a smoke test --- .gimlet/penpot-prod.yaml | 36 ++++++++++++++++++++++++++++++++++- .github/workflows/publish.yml | 17 ++++++++++++++++- 2 files changed, 51 insertions(+), 2 deletions(-) diff --git a/.gimlet/penpot-prod.yaml b/.gimlet/penpot-prod.yaml index 173fbf7c6..f3f84e2ae 100644 --- a/.gimlet/penpot-prod.yaml +++ b/.gimlet/penpot-prod.yaml @@ -139,4 +139,38 @@ manifests: | existingSecret: db-penpot-secrets secretKeys: usernameKey: username - passwordKey: password \ No newline at end of file + passwordKey: password +json6902Patches: +- target: + group: "apps" + version: "v1" + kind: "Deployment" + name: "penpot-frontend" + patch: | + --- + - op: add + path: /metadata/labels + value: + portService: tokens-studio-for-penpot +- target: + group: "apps" + version: "v1" + kind: "Deployment" + name: "penpot-exporter" + patch: | + --- + - op: add + path: /metadata/labels + value: + portService: tokens-studio-for-penpot +- target: + group: "apps" + version: "v1" + kind: "Deployment" + name: "penpot-backend" + patch: | + --- + - op: add + path: /metadata/labels + value: + portService: tokens-studio-for-penpot \ No newline at end of file diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index b9b45560c..ece4ab92f 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -70,4 +70,19 @@ jobs: GIMLET_TOKEN: ${{ secrets.GIMLET_TOKEN }} with: ENV: "prod" - APP: "penpot" \ No newline at end of file + APP: "penpot" + DEPLOY: "true" + smoke: + runs-on: ubuntu-latest + steps: + + - name: Check if URL can be accessed + run: | + URL="https://penpot.tokens.studio" + STATUS=$(curl -o /dev/null -s -w "%{http_code}\n" $URL) + if [ $STATUS -ne 200 ]; then + echo "Error: Unable to access $URL. HTTP Status: $STATUS" + exit 1 + else + echo "Success: $URL is accessible. HTTP Status: $STATUS" + fi \ No newline at end of file