docfast/.forgejo/workflows/deploy.yml
OpenClaw Deployer c6af7cd864
All checks were successful
Build & Deploy to Staging / Build & Deploy to Staging (push) Successful in 11m9s
Promote to Production / Deploy to Production (push) Successful in 2m15s
fix: disable buildx cache + simplify compression middleware
2026-02-19 08:09:59 +00:00

54 lines
1.5 KiB
YAML

name: Build & Deploy to Staging
on:
push:
branches: [ main ]
jobs:
build-and-stage:
name: Build & Deploy to Staging
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Forgejo Registry
uses: docker/login-action@v3
with:
registry: git.cloonar.com
username: openclawd
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and Push
uses: docker/build-push-action@v5
with:
context: .
push: true
no-cache: true
tags: |
git.cloonar.com/openclawd/docfast:latest
git.cloonar.com/openclawd/docfast:${{ github.sha }}
platforms: linux/arm64
- name: Deploy to Staging
run: |
curl -sLO "https://dl.k8s.io/release/$(curl -sL https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
chmod +x kubectl
echo "${{ secrets.KUBECONFIG }}" | base64 -d > /tmp/kubeconfig.yaml
./kubectl set image deployment/docfast \
docfast=git.cloonar.com/openclawd/docfast:${{ github.sha }} \
-n docfast-staging --kubeconfig=/tmp/kubeconfig.yaml
./kubectl rollout status deployment/docfast \
-n docfast-staging --kubeconfig=/tmp/kubeconfig.yaml --timeout=180s
echo "✅ Staging deploy complete!"