Skip to content

Update aws-sdk-go-v2 monorepo #2310

Update aws-sdk-go-v2 monorepo

Update aws-sdk-go-v2 monorepo #2310

Workflow file for this run

name: CI
on:
push:
branches:
- main
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
pull_request:
branches:
- main
defaults:
run:
shell: bash
permissions:
contents: read
jobs:
binary:
name: Build Binary
runs-on: ubuntu-24.04
steps:
- name: Checkout Repository
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
with:
fetch-depth: 0
- name: Setup Golang Environment
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: stable
- name: Build binary
uses: goreleaser/goreleaser-action@286f3b13b1b49da4ac219696163fb8c1c93e1200 # v6.0.0
with:
version: v2.3.2 # renovate: datasource=github-tags depName=goreleaser/goreleaser
args: build --snapshot --clean --single-target
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
unit-tests:
name: Unit Tests
runs-on: ubuntu-24.04
steps:
- name: Checkout Repository
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
- name: Setup Golang Environment
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: stable
- name: Run Tests
run: make test
build:
name: Build Packages
runs-on: ubuntu-24.04
needs: [binary, unit-tests]
permissions:
contents: write
id-token: write
steps:
- name: Checkout Repository
uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # v4.2.1
with:
fetch-depth: 0
- name: Setup Golang Environment
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version: stable
- name: Draft Release Notes
uses: lucacome/draft-release@5d29432a46bff6c122cd4b07a1fb94e1bb158d34 # v1.1.1
with:
minor-label: "enhancement"
major-label: "change"
publish: ${{ github.ref_type == 'tag' }}
collapse-after: 50
notes-footer: |
## Resources
- Documentation -- https://github.com/nginxinc/nginx-asg-sync/blob/{{version}}/README.md
if: github.event_name != 'pull_request'
- name: Download Syft
uses: anchore/sbom-action/download-syft@f5e124a5e5e1d497a692818ae907d3c45829d033 # v0.17.3
if: github.ref_type == 'tag'
- name: Install Cosign
uses: sigstore/cosign-installer@4959ce089c160fddf62f7b42464195ba1a56d382 # v3.6.0
if: github.ref_type == 'tag'
- name: Setup Snapcraft
run: |
sudo snap install snapcraft --classic
mkdir -p $HOME/.cache/snapcraft/download
mkdir -p $HOME/.cache/snapcraft/stage-packages
if: github.ref_type == 'tag'
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@286f3b13b1b49da4ac219696163fb8c1c93e1200 # v6.0.0
with:
version: v2.3.2 # renovate: datasource=github-tags depName=goreleaser/goreleaser
args: ${{ github.ref_type == 'tag' && 'release' || 'build --snapshot' }} --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_COMMUNITY }}
SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_LOGIN }}
NGINX_GITHUB_TOKEN: ${{ secrets.NGINX_PAT }}