-
Notifications
You must be signed in to change notification settings - Fork 1
58 lines (50 loc) · 1.87 KB
/
github-actions.yaml
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
58
name: RRTMGP Base Images Build
run-name: CI Image Build
on: [push]
jobs:
docker:
strategy:
matrix:
toolchain: [oneapi, nvhpc]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build minimal-toolchain:${{ matrix.toolchain }}
uses: docker/build-push-action@v6
with:
file: Dockerfile-${{ matrix.toolchain }}-minimal
tags: minimal-toolchain:${{ matrix.toolchain }}
- name: Build add-netcdf:${{ matrix.toolchain }}
uses: docker/build-push-action@v6
with:
file: Dockerfile-add-netcdf
build-args: TOOLCHAIN=${{ matrix.toolchain }}
tags: add-netcdf:${{ matrix.toolchain }}
- name: Build add-python:${{ matrix.toolchain }}
uses: docker/build-push-action@v6
with:
file: Dockerfile-add-python
build-args: TOOLCHAIN=${{ matrix.toolchain }}
tags: add-python:${{ matrix.toolchain }}
- name: Log in to Docker Hub
if: ${{ github.ref == 'refs/heads/main' }}
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Log in to the Container registry
if: ${{ github.ref == 'refs/heads/main' }}
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push rte-rrtmgp-ci:${{ matrix.toolchain }}
uses: docker/build-push-action@v6
with:
file: Dockerfile-finalize
build-args: TOOLCHAIN=${{ matrix.toolchain }}
push: ${{ github.ref == 'refs/heads/main' }}
tags: |
earthsystemradiation/rte-rrtmgp-ci:${{ matrix.toolchain }}
ghcr.io/earth-system-radiation/rte-rrtmgp-ci:${{ matrix.toolchain }}