-
-
Notifications
You must be signed in to change notification settings - Fork 18
85 lines (82 loc) · 2.66 KB
/
build-pantheon-images.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
name: Build Pantheon Images
on:
# Uncomment below for testing purposes
pull_request:
push:
branches:
- main
jobs:
buildx:
runs-on: ubuntu-24.04
env:
TERM: xterm
strategy:
fail-fast: false
matrix:
include:
- image: pantheon-index
tag: 3.6-3
context: dockerfiles/3.6-solr
- image: pantheon-index
tag: 8.8-4
context: dockerfiles/8.8-solr
- image: pantheon-appserver
tag: 8.3-4
context: dockerfiles/8.3-fpm
- image: pantheon-appserver
tag: 8.2-4
context: dockerfiles/8.2-fpm
- image: pantheon-appserver
tag: 8.1-4
context: dockerfiles/8.1-fpm
- image: pantheon-appserver
tag: 8.0-4
context: dockerfiles/8.0-fpm
- image: pantheon-appserver
tag: 7.4-4
context: dockerfiles/7.4-fpm
- image: pantheon-appserver
tag: 7.3-4
context: dockerfiles/7.3-fpm
- image: pantheon-appserver
tag: 7.2-4
context: dockerfiles/7.2-fpm
- image: pantheon-appserver
tag: 7.1-4
context: dockerfiles/7.1-fpm
- image: pantheon-appserver
tag: 7.0-4
context: dockerfiles/7.0-fpm
- image: pantheon-appserver
tag: 5.6-4
context: dockerfiles/5.6-fpm
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@v3
with:
install: true
- name: Available platforms
run: echo ${{ steps.buildx.outputs.platforms }}
- name: Set tag suffix
id: pr
if: ${{ github.event_name == 'pull_request' }}
run: echo "tag-suffix=-edge" >> $GITHUB_OUTPUT
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push devwithlando/${{ matrix.image }}:${{ matrix.tag }}${{ steps.pr.outputs.tag-suffix }}
uses: docker/build-push-action@v6
with:
context: ${{ matrix.context }}
platforms: linux/amd64,linux/arm64
push: true
tags: devwithlando/${{ matrix.image }}:${{ matrix.tag }}${{ steps.pr.outputs.tag-suffix }}
cache-from: type=gha,scope=${{ matrix.image }}-${{ matrix.tag }}
cache-to: type=gha,mode=max,scope=${{ matrix.image }}-${{ matrix.tag }}