-
Notifications
You must be signed in to change notification settings - Fork 8
51 lines (45 loc) · 1.14 KB
/
container-build.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
name: "Container Build"
on:
workflow_dispatch:
push:
branches:
- "main"
jobs:
build:
strategy:
matrix:
containers:
- tag: latest
file: Dockerfile
- tag: alpine
file: Dockerfile.alpine
- tag: nginx
file: Dockerfile.nginx
- tag: unit
file: Dockerfile.unit
- tag: httpd
file: Dockerfile.httpd
- tag: httpd-alpine
file: Dockerfile.httpd-alpine
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set up QEMU
uses: docker/setup-qemu-action@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Build container image
uses: docker/build-push-action@v3
with:
context: .
file: ${{ matrix.containers.file }}
platforms: linux/amd64
push: false
load: true
cache-from: type=gha
cache-to: type=gha,mode=max
tags: httpbin:${{ matrix.containers.tag }}
# - name: Test?
# run: |
# echo TODO