-
Notifications
You must be signed in to change notification settings - Fork 7
57 lines (53 loc) · 1.73 KB
/
quay.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
name: quay.io image
on:
# manual dispatch
workflow_dispatch:
inputs:
tag:
description: 'Docker image tag.'
required: true
jobs:
publish:
name: Build and push container
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
# extract metadata for labels https://github.com/crazy-max/ghaction-docker-meta
- name: Docker meta
id: docker_meta
uses: crazy-max/ghaction-docker-meta@v1
with:
images: quay.io/wire/roman
# setup docker actions https://github.com/docker/build-push-action
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
# login to GCR repo
- name: Login to DockerHub
uses: docker/login-action@v1
with:
registry: quay.io
username: wire+roman_github_actions
password: ${{ secrets.QUAY_PASSWORD }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v2
with:
platforms: linux/amd64
tags: quay.io/wire/roman:${{ github.event.inputs.tag }}
labels: ${{ steps.docker_meta.outputs.labels }}
push: true
build-args: |
release_version=${{ github.event.inputs.tag }}
# Send webhook to Wire using Slack Bot
- name: Webhook to Wire
uses: 8398a7/action-slack@v3
with:
status: ${{ job.status }}
author_name: Roman Quay Custom Tag Pipeline
fields: repo,message,commit,author,action,eventName,ref,workflow
env:
SLACK_WEBHOOK_URL: ${{ secrets.WEBHOOK_CI }}
# Send message only if previous step failed
if: always()