diff --git a/.github/workflows/services-www-next-required.yml b/.github/workflows/services-www-next-required.yml index b5ee6b9..409dae0 100644 --- a/.github/workflows/services-www-next-required.yml +++ b/.github/workflows/services-www-next-required.yml @@ -368,71 +368,3 @@ jobs: build-args: | COMMIT_SHA=sha-$(echo ${{ github.sha }} | cut -c1-7) VERSION=sha-$(echo ${{ github.sha }} | cut -c1-7) - - deploy: - name: Deploy - Kubernetes (GitOps) - needs: release-docker - runs-on: ubuntu-latest - if: github.event_name == 'push' && github.ref == 'refs/heads/next' - permissions: - contents: write - steps: - - name: Checkout repository - uses: actions/checkout@v4 - with: - ref: next - token: ${{ secrets.GITHUB_TOKEN }} - - - name: Setup Kustomize - uses: imranismail/setup-kustomize@v2 - with: - kustomize-version: "5.3.0" - - - name: Deploy via GitOps - run: | - WWW_TAG="sha-$(echo ${{ github.sha }} | cut -c1-7)" - bash ci/scripts/deploy-gitops.sh www "${WWW_TAG}" - - verify-rollout: - name: Verify - Production Rollout - needs: deploy - runs-on: ubuntu-latest - if: github.event_name == 'push' && github.ref == 'refs/heads/next' - steps: - - name: Await production rollout - run: | - TARGET_COMMIT="sha-$(echo ${{ github.sha }} | cut -c1-7)" - ENDPOINT="https://www.ermnvldmr.com/version.json" - - echo "========================================================" - echo "Verifying production deployment on $ENDPOINT" - echo "Expected commit: $TARGET_COMMIT" - echo "========================================================" - - MAX_ATTEMPTS=30 - ATTEMPT=1 - - while [ $ATTEMPT -le $MAX_ATTEMPTS ]; do - echo "Attempt $ATTEMPT/$MAX_ATTEMPTS: Polling $ENDPOINT..." - - RESPONSE=$(curl -sf --max-time 10 "$ENDPOINT" 2>/dev/null || true) - - if [ -n "$RESPONSE" ]; then - LIVE_COMMIT=$(echo "$RESPONSE" | jq -r '.commit // empty') - - echo " Live commit: ${LIVE_COMMIT:-}" - - if [ "$LIVE_COMMIT" = "$TARGET_COMMIT" ]; then - echo "✅ Success! Production www has successfully rolled out $TARGET_COMMIT." - exit 0 - fi - else - echo " Endpoint did not return valid JSON or timed out." - fi - - ATTEMPT=$((ATTEMPT + 1)) - sleep 10 - done - - echo "❌ Deployment verification timed out after 5 minutes." - exit 1