release.yml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. name: Release
  2. on:
  3. push:
  4. branches: [ master ]
  5. jobs:
  6. build:
  7. name: Build
  8. runs-on: ubuntu-latest
  9. strategy:
  10. matrix:
  11. goos: [linux, windows, darwin, freebsd ]
  12. goarch: [amd64, arm]
  13. exclude:
  14. - goarch: arm
  15. goos: darwin
  16. - goarch: arm
  17. goos: windows
  18. steps:
  19. - name: Check out code into the Go module directory
  20. uses: actions/checkout@v2
  21. - name: Wait for the deletion
  22. uses: jakejarvis/wait-action@master
  23. with:
  24. time: '30s'
  25. - name: Set BUILD_TIME env
  26. run: echo BUILD_TIME=$(date -u +%Y-%m-%d-%H-%M) >> ${GITHUB_ENV}
  27. - name: Go Release Binaries
  28. uses: wangyoucao577/go-release-action@v1.14
  29. with:
  30. github_token: ${{ secrets.GITHUB_TOKEN }}
  31. goos: ${{ matrix.goos }}
  32. goarch: ${{ matrix.goarch }}
  33. release_tag: dev
  34. overwrite: true
  35. build_flags: -tags 5BytesOffset # optional, default is
  36. ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
  37. # Where to run `go build .`
  38. project_path: weed
  39. binary_name: weed-large-disk
  40. asset_name: "weed-large-disk-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
  41. - name: Go Release Binaries
  42. uses: wangyoucao577/go-release-action@v1.14
  43. with:
  44. github_token: ${{ secrets.GITHUB_TOKEN }}
  45. goos: ${{ matrix.goos }}
  46. goarch: ${{ matrix.goarch }}
  47. release_tag: dev
  48. overwrite: true
  49. ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
  50. # Where to run `go build .`
  51. project_path: weed
  52. binary_name: weed-
  53. asset_name: "weed-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"