Skip to content

Merge pull request #77 from brooksn/install-zstd #8

Merge pull request #77 from brooksn/install-zstd

Merge pull request #77 from brooksn/install-zstd #8

Workflow file for this run

name: Build And Push
on:
push:
tags:
- 'v*'
permissions:
contents: read
jobs:
push-multiarch:
permissions:
contents: read
id-token: write
name: Build and Push amd64 and arm64
runs-on: ubuntu-latest
env:
TAG: ${{ github.ref_name }}
REPOSITORY_OWNER: ${{ github.repository_owner }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.ref }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: "Read secrets"
uses: rancher-eio/read-vault-secrets@main
with:
secrets: |
secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials username | DOCKER_USERNAME ;
secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials password | DOCKER_PASSWORD
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Docker Registry Login
uses: docker/login-action@v3
with:
username: ${{ env.DOCKER_USERNAME }}
password: ${{ env.DOCKER_PASSWORD }}
- name: Set the GOLANG_VERSION value
id: get-GOLANG_VERSION
run: |
echo "GO_VERSION=$(make go-version)" >> "$GITHUB_ENV"
- name: Build Container Image
uses: docker/build-push-action@v5
with:
context: .
push: true
build-args: |
"GOLANG_VERSION=${{ env.GO_VERSION }}"
tags: ${{ env.REPOSITORY_OWNER }}/hardened-build-base:${{ env.TAG }}
file: Dockerfile
platforms: linux/amd64,linux/arm64