Build(deps): Bump github.com/aws/aws-sdk-go from 1.44.220 to 1.45.24 #3196
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: Docker Build | |
on: | |
push: | |
branches: [ main ] | |
tags: [ 'v*', '!v*-pre*'] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
docker-build: | |
runs-on: ubuntu-latest | |
services: | |
registry: | |
image: registry:2 | |
ports: | |
- '5000:5000' | |
env: | |
DOCKER_BUILDKIT: 1 | |
DOCKER_CLI_EXPERIMENTAL: enabled | |
steps: | |
- name: enable experimental mode | |
run: | | |
mkdir -p ~/.docker | |
echo '{"experimental": "enabled"}' > ~/.docker/config.json | |
- name: Set up QEMU | |
uses: docker/[email protected] | |
- name: Set up Docker Buildx | |
id: buildx | |
uses: docker/[email protected] | |
with: | |
version: v0.10.4 | |
driver-opts: | | |
image=moby/buildkit:buildx-stable-1 | |
network=host | |
- name: Available platforms | |
run: echo {{ `${{ steps.buildx.outputs.platforms }}` }} | |
- run: docker info && docker version | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: determine if this is a tag | |
run: | | |
if (git describe --abbrev=0 --exact-match &>/dev/null); then | |
tag=$(git describe --abbrev=0 --exact-match) | |
echo "is_tag=true" >> $GITHUB_ENV | |
echo "git_tag=$tag" >> $GITHUB_ENV | |
# splits the major version from $tag - assumes it's a 3-part semver | |
echo "major_version=${tag%%\.*}" >> $GITHUB_ENV | |
fi | |
echo $GITHUB_ENV | |
if: github.repository == 'hairyhenderson/gomplate' | |
- name: Build & Push (non-main) | |
run: | | |
set -ex | |
make docker-multi COMMIT=${{ github.sha }} DOCKER_REPO=localhost:5000/gomplate BUILDX_ACTION=--push | |
docker buildx imagetools create --dry-run -t localhost:5000/gomplate:dev localhost:5000/gomplate:latest | |
docker buildx imagetools create --dry-run -t localhost:5000/gomplate:dev-alpine localhost:5000/gomplate:alpine | |
if: github.repository != 'hairyhenderson/gomplate' || (github.ref != 'refs/heads/main' && env.is_tag != 'true') | |
- name: Login to GHCR | |
uses: docker/[email protected] | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
if: github.repository == 'hairyhenderson/gomplate' && (github.ref == 'refs/heads/main' || env.is_tag == 'true') | |
- name: Login to DockerHub | |
uses: docker/[email protected] | |
with: | |
# NOTE: DOCKERHUB_TOKEN and DOCKERHUB_USERNAME must be present in https://github.com/hairyhenderson/gomplate/settings | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
if: github.repository == 'hairyhenderson/gomplate' && (github.ref == 'refs/heads/main' || env.is_tag == 'true') | |
- name: Build & Push (main) | |
run: | | |
make docker-multi COMMIT=${{ github.sha }} DOCKER_REPO=hairyhenderson/gomplate BUILDX_ACTION=--push | |
make docker-multi COMMIT=${{ github.sha }} DOCKER_REPO=ghcr.io/hairyhenderson/gomplate BUILDX_ACTION=--push | |
if: github.repository == 'hairyhenderson/gomplate' && github.ref == 'refs/heads/main' | |
- name: Build & Push (tagged release) | |
run: | | |
make docker-multi COMMIT=${{ github.sha }} DOCKER_REPO=hairyhenderson/gomplate BUILDX_ACTION=--push | |
make docker-multi COMMIT=${{ github.sha }} DOCKER_REPO=ghcr.io/hairyhenderson/gomplate BUILDX_ACTION=--push | |
set -x | |
export repo=hairyhenderson/gomplate | |
docker buildx imagetools create -t ${repo}:stable ${repo}:latest | |
docker buildx imagetools create -t ${repo}:${git_tag} ${repo}:latest | |
docker buildx imagetools create -t ${repo}:${major_version} ${repo}:latest | |
docker buildx imagetools create -t ${repo}:stable-alpine ${repo}:alpine | |
docker buildx imagetools create -t ${repo}:${git_tag}-alpine ${repo}:alpine | |
docker buildx imagetools create -t ${repo}:${major_version}-alpine ${repo}:alpine | |
# and now GHCR | |
export repo=ghcr.io/hairyhenderson/gomplate | |
docker buildx imagetools create -t ${repo}:stable ${repo}:latest | |
docker buildx imagetools create -t ${repo}:${git_tag} ${repo}:latest | |
docker buildx imagetools create -t ${repo}:${major_version} ${repo}:latest | |
docker buildx imagetools create -t ${repo}:stable-alpine ${repo}:alpine | |
docker buildx imagetools create -t ${repo}:${git_tag}-alpine ${repo}:alpine | |
docker buildx imagetools create -t ${repo}:${major_version}-alpine ${repo}:alpine | |
if: github.repository == 'hairyhenderson/gomplate' && env.is_tag == 'true' |