Skip to content

feat: #52 add the launch service task #64

feat: #52 add the launch service task

feat: #52 add the launch service task #64

on:
push:
branches:
- main
permissions:
contents: write
pull-requests: write
name: release-please
jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
tag_name: ${{ steps.release.outputs.tag_name }}
steps:
- uses: googleapis/release-please-action@v4
id: release
with:
token: ${{ secrets.GITHUB_TOKEN }}
release-type: go
- run: echo "release_created=${{ steps.release.outputs.release_created }}" >> "$GITHUB_OUTPUT"
- run: echo "tag_name=${{ steps.release.outputs.tag_name }}" >> "$GITHUB_OUTPUT"
set-version-and-upload:
runs-on: ubuntu-latest
needs: release-please
if: ${{ needs.release-please.outputs.release_created }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
- run: |
go build -o ptah-agent-linux-x86_64.bin \
-ldflags "-X main.version=${{ needs.release-please.outputs.tag_name }}" \
cmd/ptah-agent/ptah-agent.go
- run: gh release upload "${{ needs.release-please.outputs.tag_name }}" ptah-agent-linux-x86_64.bin
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}