-
Notifications
You must be signed in to change notification settings - Fork 2
78 lines (73 loc) · 3.78 KB
/
dockerhub.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
# This is a basic workflow to help you get started with Actions
name: Build and Push to Registry
# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
branches: [ master ]
schedule:
- cron: 0 6 * * 1,4
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
build-versions:
runs-on: ubuntu-latest
outputs:
sha: ${{ steps.short-sha.outputs.sha }}
date: ${{ steps.date.outputs.date }}
steps:
- uses: actions/checkout@v3
- uses: benjlevesque/[email protected]
id: short-sha
with:
length: 6
- name: Get current date
id: date
run: echo "date=$(date -u +'%Y%m%d')" >> $GITHUB_OUTPUT
php-latest:
needs: [build-versions, php-lower]
strategy:
matrix:
variant: [fpm, fpm-alpine, apache]
version: ['8.2']
latest: ['8']
uses: ./.github/workflows/build.yml
secrets: inherit
with:
version: ${{ matrix.version }}
variant: ${{ matrix.variant }}
tags: |
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.variant }}
${{ github.repository_owner }}/symfony:${{ matrix.variant }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant}}-${{ needs.build-versions.outputs.sha }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.sha }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant}}-${{ needs.build-versions.outputs.sha }}
${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.sha }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant }}
${{ github.repository_owner }}/symfony:${{ matrix.latest }}-${{ matrix.variant }}
php-lower:
needs: build-versions
strategy:
max-parallel: 4
matrix:
variant: [fpm, fpm-alpine, apache]
version: ['8.1', '8.0']
uses: ./.github/workflows/build.yml
secrets: inherit
with:
version: ${{ matrix.version }}
variant: ${{ matrix.variant }}
tags: |
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.date }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant}}-${{ needs.build-versions.outputs.sha }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}-${{ needs.build-versions.outputs.sha }}
ghcr.io/${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}
${{ github.repository_owner }}/symfony:${{ matrix.version }}-${{ matrix.variant }}