Lma/dockerimage #13
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 workflow | |
on: | |
pull_request: | |
branches: main | |
jobs: | |
changes: | |
runs-on: ubuntu-latest | |
permissions: | |
pull-requests: read | |
name: 'Detect changes' | |
outputs: | |
dockerfiles: ${{ steps.filter.outputs.changes }} | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v4 | |
- uses: dorny/paths-filter@v3 | |
id: filter | |
with: | |
filters: | | |
recover-id-object/scripts/Dockerfile: | |
- 'deps/concordium-rust-sdk/**' | |
- 'recover-id-object/**' | |
build-and-push: | |
needs: [ changes ] | |
if: needs.changes.outputs.dockerfiles != '[]' | |
strategy: | |
fail-fast: false | |
matrix: | |
environment: ${{ fromJSON(needs.changes.outputs.dockerfiles) }} | |
runs-on: ubuntu-latest | |
environment: production | |
steps: | |
- name: Check out the repo | |
uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Print Matrix Values | |
run: | | |
echo "Matrix ${{ matrix }}" | |
- name: Log in to DockerHub | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKER_USERNAME }} | |
password: ${{ secrets.DOCKER_TOKEN }} | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v5 | |
with: | |
context: . | |
file: ${{ matrix.dockerfile }} | |
push: true | |
tags: concordium/recover-id-object:latest |