|
34 | 34 | - name: Vet |
35 | 35 | run: CGO_ENABLED=0 go vet ./... |
36 | 36 |
|
| 37 | + bridge: |
| 38 | + name: Build Claude Bridge |
| 39 | + needs: build |
| 40 | + runs-on: ubuntu-latest |
| 41 | + if: github.ref == 'refs/heads/main' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch') |
| 42 | + strategy: |
| 43 | + matrix: |
| 44 | + include: |
| 45 | + - goos: linux |
| 46 | + goarch: amd64 |
| 47 | + - goos: linux |
| 48 | + goarch: arm64 |
| 49 | + - goos: darwin |
| 50 | + goarch: arm64 |
| 51 | + steps: |
| 52 | + - uses: actions/checkout@v4 |
| 53 | + |
| 54 | + - uses: actions/setup-go@v5 |
| 55 | + with: |
| 56 | + go-version-file: go.mod |
| 57 | + cache: true |
| 58 | + |
| 59 | + - name: Build bridge |
| 60 | + run: | |
| 61 | + cd bridge |
| 62 | + CGO_ENABLED=0 GOOS=${{ matrix.goos }} GOARCH=${{ matrix.goarch }} \ |
| 63 | + go build -ldflags="-s -w" -o claude-bridge-${{ matrix.goos }}-${{ matrix.goarch }} . |
| 64 | +
|
| 65 | + - name: Upload artifact |
| 66 | + uses: actions/upload-artifact@v4 |
| 67 | + with: |
| 68 | + name: claude-bridge-${{ matrix.goos }}-${{ matrix.goarch }} |
| 69 | + path: bridge/claude-bridge-${{ matrix.goos }}-${{ matrix.goarch }} |
| 70 | + |
37 | 71 | docker: |
38 | 72 | name: Docker Build & Push |
39 | 73 | needs: build |
@@ -73,3 +107,31 @@ jobs: |
73 | 107 | labels: ${{ steps.meta.outputs.labels }} |
74 | 108 | cache-from: type=gha |
75 | 109 | cache-to: type=gha,mode=max |
| 110 | + |
| 111 | + release-bridge: |
| 112 | + name: Release Bridge Binaries |
| 113 | + needs: bridge |
| 114 | + runs-on: ubuntu-latest |
| 115 | + if: github.ref == 'refs/heads/main' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch') |
| 116 | + permissions: |
| 117 | + contents: write |
| 118 | + steps: |
| 119 | + - uses: actions/download-artifact@v4 |
| 120 | + with: |
| 121 | + pattern: claude-bridge-* |
| 122 | + merge-multiple: true |
| 123 | + |
| 124 | + - name: Update rolling release |
| 125 | + uses: softprops/action-gh-release@v2 |
| 126 | + with: |
| 127 | + tag_name: latest |
| 128 | + name: Latest Build |
| 129 | + prerelease: true |
| 130 | + files: claude-bridge-* |
| 131 | + body: | |
| 132 | + Auto-built from `main` branch. |
| 133 | +
|
| 134 | + Download the bridge binary for your platform: |
| 135 | + - `claude-bridge-linux-amd64` — Linux x86_64 (VPS, servers) |
| 136 | + - `claude-bridge-linux-arm64` — Linux ARM64 (Raspberry Pi, ARM servers) |
| 137 | + - `claude-bridge-darwin-arm64` — macOS Apple Silicon |
0 commit comments