Skip to content

fix: binding on 0.0.0.0 (#305) #74

fix: binding on 0.0.0.0 (#305)

fix: binding on 0.0.0.0 (#305) #74

Workflow file for this run

name: Build and Deploy
on:
push:
tags:
- v*
branches: [ main ]
jobs:
build-and-push-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up QEMU for cross-architecture support
uses: docker/setup-qemu-action@v3
with:
platforms: linux/amd64,linux/arm64
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Get Vars
id: get_vars
run: |
echo "ts=$(date +%s)" >> $GITHUB_OUTPUT
echo "sha=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT
echo "branch=$(git rev-parse --abbrev-ref HEAD)" >> $GITHUB_OUTPUT
- name: "tagging release"
run: |
echo "version=${{ github.ref_name }}" >> $GITHUB_OUTPUT
if: startsWith(github.ref, 'refs/tags/v')
- name: Docker meta
id: docker_meta
uses: crazy-max/ghaction-docker-meta@v1
with:
images: |
ghcr.io/${{ github.repository }}
tag-sha: true
tag-semver: |
v{{version}}
v{{major}}.{{minor}}
tag-custom: |
${{steps.get_vars.outputs.branch}}-${{steps.get_vars.outputs.sha}}-${{ steps.get_vars.outputs.ts }}
- name: Log in to the Container registry
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
platforms: linux/amd64,linux/arm64
push: true
network: host
tags: ${{ steps.docker_meta.outputs.tags }}
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}