Rebuild images only when needed #65
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: Build & Test | |
on: | |
pull_request: | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
ompi_version: | |
- main | |
- 5.0.3 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Build the environment image | |
uses: ./.github/workflows/build-env | |
with: | |
ompi_version: ${{ matrix.ompi_version }} | |
token: ${{ secrets.GITHUB_TOKEN }} | |
max_age: 14 #days | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v2 | |
- name: Build Fenix | |
uses: docker/bake-action@v5 | |
with: | |
files: .github/docker-compose.yml | |
targets: fenix | |
set: | | |
*.output=type=docker,name=fenix | |
*.args.OMPI_VERSION=${{ matrix.ompi_version }} | |
- name: Test Fenix | |
run: docker run fenix |