-
Notifications
You must be signed in to change notification settings - Fork 0
72 lines (63 loc) · 1.86 KB
/
main.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
name: Build docker container for OpenConext Profile
on:
release:
types: [ published ]
workflow_dispatch:
push:
branches: [ develop ]
pull_request:
branches: [ develop ]
jobs:
build:
runs-on: ubuntu-latest
permissions:
packages: write
steps:
- name: Check out the repo
uses: actions/checkout@v2
- name: Log into GitHub Container Registry
uses: docker/login-action@v1
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Docker meta_phpfpm
id: metafpm
uses: docker/metadata-action@v3
with:
images: |
ghcr.io/openconext/openconext-profile/profile_php-fpm
tags: |
type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
- name: Docker meta_phpfpm
id: metaweb
uses: docker/metadata-action@v3
with:
images: |
ghcr.io/openconext/openconext-profile/profile_web
tags: |
type=schedule
type=ref,event=branch
type=ref,event=pr
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
- name: Build the php-fpm container and push to GitHub Container Registry
uses: docker/build-push-action@v2
with:
file: docker/Dockerfile
push: true
target: phpfpm-build
tags: ${{ steps.metafpm.outputs.tags }}
- name: Build the Apache container and push to GitHub Container Registry
uses: docker/build-push-action@v2
with:
file: docker/Dockerfile
push: true
target: httpd-build
tags: ${{ steps.metaweb.outputs.tags }}