-
Notifications
You must be signed in to change notification settings - Fork 155
55 lines (52 loc) · 1.56 KB
/
docker.yml
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
name: Build Docker Image
on:
push:
branches-ignore:
- 'dependabot/**'
paths-ignore:
- "*.md"
pull_request:
paths-ignore:
- "*.md"
schedule:
- cron: "0 1 * * 6" # Run at 1am every Saturday
workflow_dispatch: ~
jobs:
build-image:
name: Build Docker Image and Test Docker Compose
env:
DOCKER_BUILDKIT: 1 # Requires Latest Buildx in docker CLI
COMPOSE_DOCKER_CLI_BUILD: 1 # Requires Latest Buildx in docker compose CLI
strategy:
fail-fast: false
matrix:
platform: [linux/amd64,linux/arm64]
runs-on: ubuntu-latest
steps:
-
name: Set Up QEMU
uses: docker/setup-qemu-action@v2
-
name: Set Up Docker Buildx
uses: docker/setup-buildx-action@v2
-
name: Build Image
uses: docker/build-push-action@v3
with:
push: false
platforms: ${{ matrix.platform }}
cache-from: type=gha
cache-to: type=gha
load: true
-
name: Shutdown Default MySQL
run: sudo service mysql stop
-
name: Checkout Code
uses: actions/checkout@v3
-
name: Analyse Package
run: make analyse
-
name: Run Tests
run: make test