This repository has been archived by the owner on Apr 11, 2024. It is now read-only.
ci: update of files from global .github repo (#163) #85
This file contains 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: Release | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
test: | |
name: 'Testing' | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
go: | |
- '1.17' | |
- '1.16' | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v2 | |
- name: Setup Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: '${{ matrix.go }}' | |
- name: Invoking go test | |
run: | | |
make lint | |
make test | |
release: | |
name: 'Release to GitHub' | |
runs-on: ubuntu-latest | |
needs: | |
- test | |
steps: | |
- name: Checkout repo | |
uses: actions/checkout@v2 | |
- name: Setup Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: '1.17' | |
- name: Generating binaries | |
run: | | |
BINARY_NAME=asyncapi-event-gateway.darwin.amd64 GOOS=darwin GOARCH=amd64 make build | |
BINARY_NAME=asyncapi-event-gateway.linux.amd64 GOOS=linux GOARCH=amd64 make build | |
BINARY_NAME=asyncapi-event-gateway.windows.amd64.exe GOOS=windows GOARCH=amd64 make build | |
- name: Setup Node.js | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 14 | |
- run: docker build --tag asyncapi/event-gateway . | |
- name: Add plugin for conventional commits and docker image push | |
run: npm install conventional-changelog-conventionalcommits @semantic-release-plus/docker | |
working-directory: ./.github/workflows | |
- name: Release to GitHub | |
working-directory: ./.github/workflows | |
env: | |
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} | |
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }} | |
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} | |
GIT_AUTHOR_NAME: asyncapi-bot | |
GIT_AUTHOR_EMAIL: [email protected] | |
GIT_COMMITTER_NAME: asyncapi-bot | |
GIT_COMMITTER_EMAIL: [email protected] | |
run: npx semantic-release |