diff --git a/.github/workflows/parrotserver-release.yml b/.github/workflows/parrot-release.yml similarity index 68% rename from .github/workflows/parrotserver-release.yml rename to .github/workflows/parrot-release.yml index 088cd0913..fda669fc2 100644 --- a/.github/workflows/parrotserver-release.yml +++ b/.github/workflows/parrot-release.yml @@ -3,7 +3,7 @@ name: Parrotserver Release on: push: tags: - - parrotserver/v* + - parrot/v* jobs: release: @@ -13,6 +13,8 @@ jobs: steps: - name: Checkout repo uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1 + with: + fetch-depth: 0 - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@e3dd6a429d7300a6a4c196c26e071d42e0343502 # v4.0.2 with: @@ -25,9 +27,18 @@ jobs: mask-password: 'true' env: AWS_REGION: ${{ secrets.QA_AWS_REGION }} - - name: Build and release + - name: Set up Go + uses: actions/setup-go@v5 + with: + go-version: stable + - name: Goreleaser Release + uses: goreleaser/goreleaser-action@v6 + with: + distribution: goreleaser-pro + version: "~> v2" + args: release --clean env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - IMAGE_PREFIX: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/parrotserver + GORELEASER_KEY: ${{ secrets.GORELEASER_KEY }} + IMAGE_PREFIX: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/parrot IMAGE_TAG: ${{ github.ref_name}} - run: goreleaser release --clean -f ./parrotserver/.goreleaser.yml diff --git a/parrot/.goreleaser.yaml b/parrot/.goreleaser.yaml index f663c839b..758fccc0a 100644 --- a/parrot/.goreleaser.yaml +++ b/parrot/.goreleaser.yaml @@ -1,10 +1,10 @@ # yaml-language-server: $schema=https://goreleaser.com/static/schema-pro.json -version: 1 -project_name: parrotserver +version: 2 +project_name: parrot monorepo: - tag_prefix: parrotserver/ - dir: parrotserver + tag_prefix: parrot/ + dir: parrot env: - IMG_PRE={{ if index .Env "IMAGE_PREFIX" }}{{ .Env.IMAGE_PREFIX }}{{ else }}local{{ end }} @@ -12,7 +12,7 @@ env: # Build settings for binaries builds: - - id: parrotserver + - id: parrot goos: - linux - darwin @@ -26,12 +26,12 @@ archives: - format: binary dockers: - - id: linux-amd64-parrotserver + - id: linux-amd64-parrot goos: linux goarch: amd64 image_templates: - - '{{ .Env.IMG_PRE }}/parrotserver:{{ .Tag }}' - - '{{ .Env.IMG_PRE }}/parrotserver:latest' + - '{{ .Env.IMG_PRE }}/parrot:{{ .Tag }}' + - '{{ .Env.IMG_PRE }}/parrot:latest' build_flag_templates: - --platform=linux/amd64 - --pull @@ -39,12 +39,12 @@ dockers: - --label=org.opencontainers.image.title={{.ProjectName}} - --label=org.opencontainers.image.revision={{.FullCommit}} - --label=org.opencontainers.image.version={{.Version}} - - id: linux-arm64-parrotserver + - id: linux-arm64-parrot goos: linux goarch: arm64 image_templates: - - '{{ .Env.IMG_PRE }}/parrotserver:{{ .Tag }}-arm64' - - '{{ .Env.IMG_PRE }}/parrotserver:latest-arm64' + - '{{ .Env.IMG_PRE }}/parrot:{{ .Tag }}-arm64' + - '{{ .Env.IMG_PRE }}/parrot:latest-arm64' build_flag_templates: - --platform=linux/arm64 - --pull @@ -55,4 +55,4 @@ dockers: before: hooks: - - cd parrotserver && go mod tidy \ No newline at end of file + - cd parrot && go mod tidy \ No newline at end of file