Implemented gocbcorex based helper for caodeploy. #112
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Release | |
| permissions: | |
| contents: write | |
| on: | |
| push: | |
| tags: | |
| - v* | |
| jobs: | |
| build: | |
| name: Build | |
| runs-on: ubuntu-24.04 | |
| strategy: | |
| matrix: | |
| platform: [darwin, linux, windows] | |
| arch: [amd64, arm64] | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: actions/setup-go@v2 | |
| with: | |
| go-version: 1.21 | |
| - name: Install dependencies | |
| run: go get . | |
| - name: Build Binary | |
| run: GOOS=${{ matrix.platform }} GOARCH=${{ matrix.arch }} CGO_ENABLED=0 go build -o cbdinocluster-${{ matrix.platform }}-${{ matrix.arch }} -ldflags="-X github.com/couchbaselabs/cbdinocluster/contrib/buildversion.MainPkgVersion=${{ github.ref_name }}" | |
| - uses: actions/upload-artifact@v4 | |
| with: | |
| name: cbdinocluster-${{ matrix.platform }}-${{ matrix.arch }} | |
| path: cbdinocluster-${{ matrix.platform }}-${{ matrix.arch }} | |
| publish: | |
| name: Publish | |
| needs: [build] | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-linux-amd64 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-linux-arm64 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-darwin-amd64 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-darwin-arm64 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-windows-amd64 | |
| - uses: actions/download-artifact@v4 | |
| with: | |
| name: cbdinocluster-windows-arm64 | |
| - name: Rename Windows Amd64 Binary | |
| run: mv cbdinocluster-windows-amd64 cbdinocluster-windows-amd64.exe | |
| - name: Rename Windows Arm64 Binary | |
| run: mv cbdinocluster-windows-arm64 cbdinocluster-windows-arm64.exe | |
| - name: Release | |
| uses: softprops/action-gh-release@v1 | |
| with: | |
| files: | | |
| cbdinocluster-darwin-amd64 | |
| cbdinocluster-darwin-arm64 | |
| cbdinocluster-linux-amd64 | |
| cbdinocluster-linux-arm64 | |
| cbdinocluster-windows-amd64.exe | |
| cbdinocluster-windows-arm64.exe |