mirror of
https://github.com/etkecc/synapse-admin.git
synced 2024-12-29 19:18:15 +03:00
37ed5c4156
Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 1 to 2. - [Release notes](https://github.com/docker/setup-qemu-action/releases) - [Commits](https://github.com/docker/setup-qemu-action/compare/v1...v2) --- updated-dependencies: - dependency-name: docker/setup-qemu-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
51 lines
1.5 KiB
YAML
51 lines
1.5 KiB
YAML
name: Create docker image(s) and push to docker hub
|
|
|
|
on:
|
|
push:
|
|
# Sequence of patterns matched against refs/heads
|
|
# prettier-ignore
|
|
branches:
|
|
# Push events on master branch
|
|
- master
|
|
# Sequence of patterns matched against refs/tags
|
|
tags:
|
|
- '[0-9]+\.[0-9]+\.[0-9]+' # Push events to 0.X.X tag
|
|
|
|
jobs:
|
|
docker:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@v2
|
|
- name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v2
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v1
|
|
- name: Login to DockerHub
|
|
uses: docker/login-action@v1
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_TOKEN }}
|
|
- name: Calculate docker image tag
|
|
id: set-tag
|
|
run: |
|
|
case "${GITHUB_REF}" in
|
|
refs/heads/master|refs/heads/main)
|
|
tag=latest
|
|
;;
|
|
refs/tags/*)
|
|
tag=${GITHUB_REF#refs/tags/}
|
|
;;
|
|
*)
|
|
tag=${GITHUB_SHA}
|
|
;;
|
|
esac
|
|
echo "::set-output name=tag::$tag"
|
|
- name: Build and Push Tag
|
|
uses: docker/build-push-action@v3
|
|
with:
|
|
context: .
|
|
push: true
|
|
tags: "awesometechnologies/synapse-admin:${{ steps.set-tag.outputs.tag }}"
|
|
platforms: linux/amd64,linux/arm64
|