2022-10-30 14:44:14 +03:00
|
|
|
name: Build base images
|
|
|
|
|
|
|
|
on:
|
|
|
|
schedule:
|
|
|
|
- cron: '0 0 * * *'
|
|
|
|
|
|
|
|
env:
|
|
|
|
BASE_IMAGE_NAME: php
|
2023-12-10 21:26:58 +03:00
|
|
|
BASE_IMAGE_VERSION: "8.2"
|
2022-10-30 14:44:14 +03:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
build-cli:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
lfs: false
|
|
|
|
|
|
|
|
- name: Set up QEMU
|
|
|
|
uses: docker/setup-qemu-action@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
id: buildx
|
|
|
|
uses: docker/setup-buildx-action@v2
|
|
|
|
|
2024-06-10 00:50:18 +03:00
|
|
|
- name: Change repository string to lowercase
|
|
|
|
id: repositorystring
|
|
|
|
uses: Entepotenz/change-string-case-action@v1
|
|
|
|
with:
|
|
|
|
string: ${{ github.repository }}
|
|
|
|
|
2022-10-30 14:44:14 +03:00
|
|
|
- name: Log into registry
|
|
|
|
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
|
|
|
|
|
|
|
|
- name: Build cli image
|
|
|
|
run: |
|
2024-06-10 00:50:18 +03:00
|
|
|
IMAGE_NAME=ghcr.io/${{ steps.repositorystring.outputs.lowercase }}/$BASE_IMAGE_NAME:$BASE_IMAGE_VERSION-cli
|
2022-10-30 14:44:14 +03:00
|
|
|
|
|
|
|
docker buildx build --platform linux/amd64,linux/arm64 -t $IMAGE_NAME . --push -f install/automated/docker/base-php-cli.Dockerfile --build-arg VERSION=$BASE_IMAGE_VERSION
|
|
|
|
|
|
|
|
build-apache:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
with:
|
|
|
|
lfs: false
|
|
|
|
|
|
|
|
- name: Set up QEMU
|
|
|
|
uses: docker/setup-qemu-action@v2
|
|
|
|
|
|
|
|
- name: Set up Docker Buildx
|
|
|
|
id: buildx
|
|
|
|
uses: docker/setup-buildx-action@v2
|
2024-06-10 00:50:18 +03:00
|
|
|
|
|
|
|
- name: Change repository string to lowercase
|
|
|
|
id: repositorystring
|
|
|
|
uses: Entepotenz/change-string-case-action@v1
|
|
|
|
with:
|
|
|
|
string: ${{ github.repository }}
|
2022-10-30 14:44:14 +03:00
|
|
|
|
|
|
|
- name: Log into registry
|
|
|
|
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.actor }} --password-stdin
|
2024-06-10 00:50:18 +03:00
|
|
|
|
2022-10-30 14:44:14 +03:00
|
|
|
- name: Build apache image
|
|
|
|
run: |
|
2024-06-10 00:50:18 +03:00
|
|
|
IMAGE_NAME=ghcr.io/${{ steps.repositorystring.outputs.lowercase }}/$BASE_IMAGE_NAME:$BASE_IMAGE_VERSION-apache
|
2022-10-30 14:44:14 +03:00
|
|
|
|
|
|
|
docker buildx build --platform linux/amd64,linux/arm64 -t $IMAGE_NAME . --push -f install/automated/docker/base-php-apache.Dockerfile --build-arg VERSION=$BASE_IMAGE_VERSION
|