-
Notifications
You must be signed in to change notification settings - Fork 39
50 lines (45 loc) · 1.27 KB
/
update-base-image.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
name: Build base images
on:
workflow_dispatch:
schedule:
- cron: '0 */6 * * *'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
os:
- debian
- centos
otp:
- "24.0"
ghc:
- "8.10.4"
cabal:
- "3.4.0.0"
steps:
- uses: actions/checkout@v2
- uses: docker/setup-buildx-action@v1
- uses: docker/setup-qemu-action@v1
with:
image: tonistiigi/binfmt:latest
platforms: all
- uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ github.token }}
- uses: docker/build-push-action@v2
with:
push: true
pull: true
cache-from: type=registry,ref=ghcr.io/${{ github.repository }}/base
platforms: 'linux/amd64'
tags: "ghcr.io/${{ github.repository }}/base:otp${{ matrix.otp }}-ghc${{ matrix.ghc }}-cabal${{ matrix.cabal }}-${{ matrix.os }}"
build-args: |
OTP_VERSION=${{ matrix.otp }}
GHC_VERSION=${{ matrix.ghc }}
CABAL_VERSION=${{ matrix.cabal }}
file: .github/dockerfile/Dockerfile.${{ matrix.os }}
context: .