diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 4be6605..e162d1a 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -29,46 +29,6 @@ jobs: - name: Build run: bun run build - deploy: - needs: ci - if: gitea.ref == 'refs/heads/Develop' && gitea.event_name == 'push' - runs-on: dind - steps: - - name: Clone repository - run: | - apk add --no-cache git curl docker-cli docker-cli-buildx - git clone https://${{ secrets.GITEA_TOKEN }}@gitea.jeanlucmakiola.de/${{ gitea.repository }}.git repo - cd repo - git checkout Develop - - - name: Build and push Docker image - working-directory: repo - run: | - REGISTRY="gitea.jeanlucmakiola.de" - IMAGE="${REGISTRY}/${{ gitea.repository_owner }}/gearbox" - echo "${{ secrets.REGISTRY_TOKEN }}" | docker login "$REGISTRY" -u "${{ gitea.repository_owner }}" --password-stdin - docker buildx build \ - --cache-from type=registry,ref=${IMAGE}:buildcache \ - --cache-to type=registry,ref=${IMAGE}:buildcache \ - -t "${IMAGE}:develop" \ - --push . - - - name: Trigger Coolify deploy - env: - COOLIFY_TOKEN: ${{ secrets.COOLIFY_TOKEN }} - COOLIFY_WEBHOOK: ${{ vars.COOLIFY_WEBHOOK }} - run: | - TOKEN=$(printf '%s' "${COOLIFY_TOKEN}" | tr -d '[:space:]') - RESPONSE=$(curl -s -w '\n%{http_code}' -X GET "${COOLIFY_WEBHOOK}" \ - -H "Authorization: Bearer ${TOKEN}") - STATUS=$(echo "$RESPONSE" | tail -1) - BODY=$(echo "$RESPONSE" | sed '$d') - echo "Coolify deploy: HTTP ${STATUS}" - if [ "$STATUS" -ge 400 ]; then - echo "::error::Coolify deploy failed with HTTP ${STATUS} - ${BODY}" - exit 1 - fi - e2e: if: false # E2E tests need rewrite: auth moved from local login to OIDC (Logto). Tests still expect username/password flow. needs: ci diff --git a/.gitea/workflows/release.yml b/.gitea/workflows/release.yml index ca3755d..6f98c8c 100644 --- a/.gitea/workflows/release.yml +++ b/.gitea/workflows/release.yml @@ -28,11 +28,11 @@ jobs: release: needs: ci - runs-on: dind + runs-on: light steps: - name: Clone repository run: | - apk add --no-cache git curl jq docker-cli docker-cli-buildx + apt-get update && apt-get install -y --no-install-recommends jq git clone https://${{ secrets.GITEA_TOKEN }}@gitea.jeanlucmakiola.de/${{ gitea.repository }}.git repo cd repo git checkout ${{ gitea.ref_name }} @@ -61,18 +61,6 @@ jobs: echo "$CHANGELOG" >> "$GITHUB_ENV" echo "CHANGELOG_EOF" >> "$GITHUB_ENV" - - name: Build and push Docker image - working-directory: repo - run: | - REGISTRY="gitea.jeanlucmakiola.de" - IMAGE="${REGISTRY}/${{ gitea.repository_owner }}/gearbox" - echo "${{ secrets.REGISTRY_TOKEN }}" | docker login "$REGISTRY" -u "${{ gitea.repository_owner }}" --password-stdin - docker buildx build \ - --cache-from type=registry,ref=${IMAGE}:buildcache \ - --cache-to type=registry,ref=${IMAGE}:buildcache \ - -t "${IMAGE}:${VERSION}" -t "${IMAGE}:latest" \ - --push . - - name: Create Gitea release run: | API_URL="${GITHUB_SERVER_URL}/api/v1/repos/${{ gitea.repository }}/releases" diff --git a/CLAUDE.md b/CLAUDE.md index b014af2..af0a379 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -64,7 +64,7 @@ bun run build # Vite build → dist/client/ ## Releasing -Releases are tag-driven. The Gitea Actions workflow (`.gitea/workflows/release.yml`) triggers on any pushed tag matching `v*` — it runs CI (lint, test, build), generates a changelog from the previous tag, builds and pushes a Docker image, and creates a Gitea release. The version comes from the tag name. +Releases are tag-driven. The Gitea Actions workflow (`.gitea/workflows/release.yml`) triggers on any pushed tag matching `v*` — it runs CI (lint, test, build), generates a changelog from the previous tag, and creates a Gitea release. (The Docker image build was removed when the dind runner was retired.) The version comes from the tag name. To release, tag the desired commit on `Develop` and push: ```bash