fix(SPV-1070): improve look and feel for broken paymail autocomplete … #80
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: release | |
on: | |
push: | |
tags: | |
- 'v*.*.*' | |
permissions: | |
contents: write | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Setup Dockerhub repo based on var | |
if: vars.DOCKERHUB_REPO != null | |
run: | | |
echo "DOCKERHUB_REPO=${{vars.DOCKERHUB_REPO}}" >> $GITHUB_ENV | |
- name: Default Dockerhub repo to on project name | |
if: vars.DOCKERHUB_REPO == null | |
run: | | |
echo "DOCKERHUB_REPO=$(basename ${GITHUB_REPOSITORY})" >> $GITHUB_ENV | |
- name: Setup Dockerhub owner based on var | |
if: vars.DOCKERHUB_OWNER != null | |
run: | | |
echo "DOCKERHUB_OWNER=${{vars.DOCKERHUB_OWNER}}" >> $GITHUB_ENV | |
- name: Default Dockerhub owner to dockerhub username | |
if: vars.DOCKERHUB_OWNER == null | |
run: | | |
echo "DOCKERHUB_OWNER=${{secrets.DOCKERHUB_USERNAME}}" >> $GITHUB_ENV | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Make directory for release artifacts | |
run: | | |
mkdir -p ./release/artifacts | |
- name: Prepare README for dockerhub | |
run: | | |
envsubst < ./release/README.DOCKER.md > ./release/artifacts/README.DOCKER.md | |
- name: Docker meta | |
id: meta | |
uses: docker/metadata-action@v5 | |
with: | |
images: ${{ env.DOCKERHUB_OWNER }}/${{ env.DOCKERHUB_REPO }} | |
tags: | | |
type=semver,pattern=v{{version}} | |
type=semver,pattern=v{{major}}.{{minor}} | |
type=semver,pattern=v{{major}} | |
type=semver,pattern=v{{version}} | |
- name: Set up QEMU | |
uses: docker/setup-qemu-action@v3 | |
- name: Login to Docker Hub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Build and push | |
uses: docker/build-push-action@v6 | |
with: | |
context: . | |
file: ./release/Dockerfile | |
platforms: linux/amd64,linux/arm64 | |
push: true | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
- name: Docker Hub Description | |
uses: peter-evans/dockerhub-description@v4 | |
with: | |
username: ${{ secrets.DOCKERHUB_USERNAME }} | |
password: ${{ secrets.DOCKERHUB_TOKEN }} | |
short-description: ${{ github.event.repository.description }} | |
repository: ${{ env.DOCKERHUB_OWNER }}/${{ env.DOCKERHUB_REPO }} | |
readme-filepath: ./release/artifacts/README.DOCKER.md | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
- name: Go Release | |
uses: goreleaser/goreleaser-action@v6 | |
with: | |
distribution: goreleaser | |
version: v1 | |
args: -f release/.goreleaser.yml release --clean | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |