Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .docker/Dockerfile.apache
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM php:8.3-apache
FROM php:8.3.36-apache@sha256:756c2884677bedea30afaa95811b42cd3ff251203291c5820c1ad209e86c9fb4



LABEL vendor="Mautic"
LABEL maintainer="LibreCode coop"
Expand Down
4 changes: 3 additions & 1 deletion .docker/Dockerfile.fpm
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM php:8.3-fpm
FROM php:8.3.36-fpm@sha256:d0dea3f5d95314eac94a732469f4cf0ee658a22c2ce3f2612272b9d5b42d1a72



LABEL vendor="Mautic"
LABEL maintainer="LibreCode coop"
Expand Down
1 change: 1 addition & 0 deletions .docker/scripts/entrypoint_mautic_cron.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ chmod 777 /tmp/stdout
# so the jobs need an explicit shell environment.
{
declare -p | grep -E '^(declare -x (PHP_INI_VALUE_|MAUTIC_DB_|MAUTIC_SITE_URL))'
# shellcheck disable=SC2016
printf '%s\n' 'if [ -n "${MAUTIC_DB_NAME:-}" ] && [ -z "${MAUTIC_DB_DATABASE:-}" ]; then export MAUTIC_DB_DATABASE="$MAUTIC_DB_NAME"; fi'
} > /tmp/cron.env

Expand Down
10 changes: 8 additions & 2 deletions .github/workflows/build_publish.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
name: Build and publish a Docker image

on:
pull_request:
branches:
- main
push:
branches:
- main
Expand Down Expand Up @@ -34,7 +37,7 @@ jobs:
name: Build image
runs-on: ubuntu-latest
env:
MAUTIC_VERSION: ${{ github.event_name == 'workflow_dispatch' && inputs.mautic_version || (github.ref == 'refs/heads/main' && '7.x-dev') || github.ref_name }}
MAUTIC_VERSION: ${{ github.event_name == 'workflow_dispatch' && inputs.mautic_version || (github.event_name == 'pull_request' && '7.x-dev') || (github.ref == 'refs/heads/main' && '7.x-dev') || github.ref_name }}
strategy:
fail-fast: false
matrix:
Expand All @@ -58,6 +61,7 @@ jobs:
type=semver,pattern={{major}}.{{minor}},value=${{ env.MAUTIC_VERSION }},enable=${{ github.event_name == 'workflow_dispatch' && inputs.overwrite_latest_minor }}
type=semver,pattern={{major}},value=${{ env.MAUTIC_VERSION }},enable=${{ github.event_name == 'workflow_dispatch' && inputs.overwrite_latest_major }}
type=raw,value=7.x-dev,enable=${{ github.ref == 'refs/heads/main' }},suffix=-${{ matrix.image_type }}
type=raw,value=pr-check,enable=${{ github.event_name == 'pull_request' }}
type=raw,value=latest,enable=${{ github.event_name == 'workflow_dispatch' && inputs.tag_as_latest && matrix.image_type == 'apache' }},suffix=
flavor: |
latest=false
Expand All @@ -75,6 +79,7 @@ jobs:
restore-keys: |
${{ matrix.image_type }}-buildx-
- name: Log in to GitHub Container Registry
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
registry: ghcr.io
Expand All @@ -83,7 +88,8 @@ jobs:
- name: Build and publish container image
uses: docker/build-push-action@v6
with:
push: ${{ github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/') || inputs.publish }}
pull: true
push: ${{ github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/tags/') || inputs.publish == true }}
context: .docker
platforms: linux/amd64,linux/arm64
file: .docker/Dockerfile.${{ matrix.image_type }}
Expand Down
Loading