Merge pull request #104 from it-at-m/feature-zms-1808-appoinrment-red… #604
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build images | |
on: | |
push: | |
tags: | |
- '**' | |
branches: | |
- '**' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout GitHub Action | |
uses: actions/checkout@main | |
- name: Install python3 | |
run: sudo apt install -y python3 python3-click python3-git | |
- name: Referencing local Modules and Libraries | |
run: python3 ./cli modules reference-libraries --no-symlink | |
- name: Login to GitHub Container Registry | |
uses: docker/login-action@v1 | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Set Swap Space | |
uses: pierotofy/set-swap-space@master | |
with: | |
swap-size-gb: 10 | |
- name: Build Image | |
run: | | |
tag="${{ github.ref_name }}" | |
if [ "${{ github.ref_type }}" = "branch" ]; then | |
tag="branch-$tag" | |
fi | |
docker build . \ | |
--file ".resources/Containerfile" \ | |
--tag "ghcr.io/${{ github.repository }}/${{ matrix.module }}:$tag" \ | |
--build-arg "MODULE=${{ matrix.module }}" \ | |
--build-arg "PHP_VERSION=${{ matrix.php_version }}" | |
docker push "ghcr.io/${{ github.repository }}/${{ matrix.module }}:$tag" | |
strategy: | |
matrix: | |
include: | |
- module: zmsadmin | |
php_version: "8.0" | |
- module: zmsapi | |
php_version: "8.0" | |
- module: zmscalldisplay | |
php_version: "7.3" | |
- module: zmsmessaging | |
php_version: "8.0" | |
- module: zmsstatistic | |
php_version: "8.0" |