Prepare for 0.7.4 release #34
Workflow file for this run
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: cd | |
on: | |
push: | |
tags: | |
- '*' | |
jobs: | |
release: | |
name: Release | |
strategy: | |
matrix: | |
go-version: [1.19.2] | |
os: [ubuntu-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install Go | |
uses: actions/setup-go@v2 | |
with: | |
go-version: ${{ matrix.go-version }} | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Build all | |
run: make all | |
- name: Extract tag version from ref | |
id: get_version | |
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | |
- name: Publish docker image locally for Snyk action | |
run: make docker-build | |
- name: Run Snyk to monitor vulnerabilities in Docker image | |
uses: snyk/actions/docker@master | |
if: ${{ !contains(github.ref, 'rc') }} | |
with: | |
image: "snowplow/dataflow-runner:${{ github.ref_name }}" | |
args: "--app-vulns --org=data-processing-new" | |
command: monitor | |
env: | |
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }} | |
- name: Create GitHub release and attach artifacts | |
uses: softprops/action-gh-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
draft: true | |
prerelease: ${{ contains(github.ref , '-') }} | |
name: Version ${{ github.ref_name }} | |
tag_name: ${{ github.ref_name }} | |
files: | | |
build/bin/dataflow_runner_${{ github.ref_name }}_darwin_amd64.zip | |
build/bin/dataflow_runner_${{ github.ref_name }}_linux_amd64.zip | |
build/bin/dataflow_runner_${{ github.ref_name }}_windows_amd64.zip | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v2 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to DockerHub | |
uses: docker/login-action@v2 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
- name: Publish docker image | |
run: make docker-cross-build-publish |