Merge pull request #375 from deNBI/deps/zipp-3.x #271
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: Publish Docker | |
on: | |
push: | |
branches: | |
- 'dev' | |
- 'staging' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Workflow run cleanup action | |
uses: rokroskar/[email protected] | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
- uses: actions/checkout@master | |
- name: Extract branch name | |
shell: bash | |
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" | |
id: extract_branch | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Login to Quay.io | |
uses: docker/login-action@v2 | |
with: | |
registry: quay.io | |
username: ${{ secrets.QUAY_USERNAME }} | |
password: ${{ secrets.QUAY_TOKEN }} | |
- name: Build and publish image to Quay | |
uses: docker/build-push-action@v4 | |
with: | |
file: Dockerfile | |
push: true | |
tags: quay.io/denbicloud/os_project_usage_exporter:${{ steps.extract_branch.outputs.branch }} | |