diff --git a/.woodpecker/ci.yaml b/.woodpecker/ci.yaml index 2d0d788..550ce5e 100644 --- a/.woodpecker/ci.yaml +++ b/.woodpecker/ci.yaml @@ -19,8 +19,11 @@ steps: image: node:20-alpine commands: - corepack enable && corepack prepare pnpm@10.28.2 --activate + - pnpm install --frozen-lockfile || pnpm install - pnpm run lint - pnpm run lint:css + depends_on: + - install - name: Send Lint Status Notification (failure) image: curlimages/curl @@ -29,7 +32,7 @@ steps: from_secret: mattermost_test_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Lint failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Lint failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - lint @@ -40,7 +43,10 @@ steps: image: node:20-alpine commands: - corepack enable && corepack prepare pnpm@10.28.2 --activate + - pnpm install --frozen-lockfile || pnpm install - pnpm run build + depends_on: + - install - name: Send Test Build Status Notification (failure) image: curlimages/curl @@ -49,7 +55,7 @@ steps: from_secret: mattermost_test_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Test build failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Test build failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - build @@ -60,7 +66,10 @@ steps: image: node:20-alpine commands: - corepack enable && corepack prepare pnpm@10.28.2 --activate + - pnpm install --frozen-lockfile || pnpm install - pnpm test + depends_on: + - install - name: Send Unit Test Status Notification (failure) image: curlimages/curl @@ -69,7 +78,7 @@ steps: from_secret: mattermost_test_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Unit test failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Unit test failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - unit test @@ -93,7 +102,7 @@ steps: from_secret: mattermost_test_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] E2E test failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] E2E test failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - e2e test @@ -107,7 +116,7 @@ steps: from_secret: mattermost_test_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] CI pipeline success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] CI pipeline success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - install diff --git a/.woodpecker/deploy.yaml b/.woodpecker/deploy.yaml index 7769cdd..4c9dff4 100644 --- a/.woodpecker/deploy.yaml +++ b/.woodpecker/deploy.yaml @@ -39,7 +39,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Build success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Build success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - 'Docker image build' @@ -53,7 +53,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Build failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Build failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - Docker image build @@ -94,7 +94,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Push to registry success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Push to registry success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - 'Push to registry' @@ -108,7 +108,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Push to registry failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Push to registry failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - 'Push to registry' @@ -142,7 +142,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Production Deploy success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Production Deploy success 🎉"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - 'Trigger Portainer stack redeploy' @@ -156,7 +156,7 @@ steps: from_secret: mattermost_deploy_webhook commands: - | - BODY=$(printf '{"username":"WoodpeckerBot","content":"[%s - Build #%s] Production Deploy failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") + BODY=$(printf '{"username":"WoodpeckerBot","text":"[%s - Build #%s] Production Deploy failure 💩"}' "$CI_REPO" "$CI_PIPELINE_NUMBER") curl -sS -X POST -H "Content-Type: application/json" -d "$BODY" "$MATTERMOST_WEBHOOK_URL" depends_on: - Trigger Portainer stack redeploy