Refactored php 5 on alpine linux, reworked all action workflows, changed registry to quay.io
Build and push Nginx on alpine based container images / Build nginx container images (cli, map[os:alpine os_version:3.5 php_ver_short:5 php_version:5.6]) (push) Failing after 24s Details
Build and push Nginx on alpine based container images / Build nginx container images (debug, map[os:alpine os_version:3.5 php_ver_short:5 php_version:5.6]) (push) Failing after 25s Details
Build and push Nginx on alpine based container images / Build nginx container images (full, map[os:alpine os_version:3.5 php_ver_short:5 php_version:5.6]) (push) Failing after 23s Details

This commit is contained in:
Muhamad Aditya Prima 2024-12-16 17:17:32 +07:00
parent 0254cbad61
commit 37b27a14f9
9 changed files with 152 additions and 1246 deletions

View File

@ -1,252 +0,0 @@
name: Build and Push Alpine PHP Image
on:
push:
branches:
- master
jobs:
build:
name: Build and push image
runs-on: ubuntu-latest
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 5.6
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.5
PHP_VERSION=5
push: true
tags: |
aprimediet/php:5.6-alpine
aprimediet/php:5-alpine
- name: Build and push 7.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.9
PHP_VERSION=7
push: true
tags: |
aprimediet/php:7.2-alpine
- name: Build and push 7.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.10
PHP_VERSION=7
push: true
tags: |
aprimediet/php:7.3-alpine
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.13
PHP_VERSION=7
push: true
tags: |
aprimediet/php:7.4-alpine
aprimediet/php:7-alpine
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.16
PHP_VERSION=8
push: true
tags: |
aprimediet/php:8.0-alpine
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.18
PHP_VERSION=81
push: true
tags: |
aprimediet/php:8.1-alpine
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.18
PHP_VERSION=82
push: true
tags: |
aprimediet/php:8.2-alpine
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.19
PHP_VERSION=83
push: true
tags: |
aprimediet/php:8.3-alpine
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
ALPINE_VERSION=3.21
PHP_VERSION=84
push: true
tags: |
aprimediet/php:8.4-alpine
aprimediet/php:8-alpine
aprimediet/php:alpine
build-apache:
name: Build and push apache image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 5.6 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.5
PHP_VERSION=5
PHP=5.6
push: true
tags: |
aprimediet/php:5.6-apache-alpine
aprimediet/php:5-apache-alpine
- name: Build and push 7.2 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.9
PHP_VERSION=7
PHP=7.2
push: true
tags: |
aprimediet/php:7.2-apache-alpine
- name: Build and push 7.3 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.10
PHP_VERSION=7
PHP=7.3
push: true
tags: |
aprimediet/php:7.3-apache-alpine
- name: Build and push 7.4 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.13
PHP_VERSION=7
PHP=7.4
push: true
tags: |
aprimediet/php:7.4-apache-alpine
aprimediet/php:7-apache-alpine
- name: Build and push 8.0 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.16
PHP_VERSION=8
PHP=8.0
push: true
tags: |
aprimediet/php:8.0-apache-alpine
- name: Build and push 8.1 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.18
PHP_VERSION=81
PHP=8.1
push: true
tags: |
aprimediet/php:8.1-apache-alpine
- name: Build and push 8.2 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.18
PHP_VERSION=82
PHP=8.2
push: true
tags: |
aprimediet/php:8.2-apache-alpine
- name: Build and push 8.3 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.19
PHP_VERSION=83
PHP=8.3
push: true
tags: |
aprimediet/php:8.3-apache-alpine
- name: Build and push 8.4 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
ALPINE_VERSION=3.21
PHP_VERSION=84
PHP=8.4
push: true
tags: |
aprimediet/php:8.4-apache-alpine
aprimediet/php:8-apache-alpine
aprimediet/php:apache-alpine

View File

@ -1,270 +0,0 @@
name: Build and Push Alpine PHP Image
on:
push:
branches:
- master
jobs:
build:
name: Build and push image
runs-on: ubuntu-latest
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Winter Access Git Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 5.6
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.5
PHP_VERSION=5
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:5.6-alpine
git.winteraccess.id/${{ gitea.repository }}:5-alpine
- name: Build and push 7.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.9
PHP_VERSION=7
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.2-alpine
- name: Build and push 7.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.10
PHP_VERSION=7
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.3-alpine
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.13
PHP_VERSION=7
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-alpine
git.winteraccess.id/${{ gitea.repository }}:7-alpine
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.16
PHP_VERSION=8
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-alpine
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.18
PHP_VERSION=81
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-alpine
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.18
PHP_VERSION=82
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-alpine
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.19
PHP_VERSION=83
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-alpine
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.21
PHP_VERSION=84
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-alpine
git.winteraccess.id/${{ gitea.repository }}:8-alpine
git.winteraccess.id/${{ gitea.repository }}:alpine
build-apache:
name: Build and push apache image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Winter Access Git Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 5.6 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.5
PHP_VERSION=5
PHP=5.6
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:5.6-apache-alpine
git.winteraccess.id/${{ gitea.repository }}:5-apache-alpine
- name: Build and push 7.2 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.9
PHP_VERSION=7
PHP=7.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.2-apache-alpine
- name: Build and push 7.3 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.10
PHP_VERSION=7
PHP=7.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.3-apache-alpine
- name: Build and push 7.4 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.13
PHP_VERSION=7
PHP=7.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-apache-alpine
git.winteraccess.id/${{ gitea.repository }}:7-apache-alpine
- name: Build and push 8.0 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.16
PHP_VERSION=8
PHP=8.0
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-apache-alpine
- name: Build and push 8.1 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.18
PHP_VERSION=81
PHP=8.1
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-apache-alpine
- name: Build and push 8.2 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.18
PHP_VERSION=82
PHP=8.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-apache-alpine
- name: Build and push 8.3 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.19
PHP_VERSION=83
PHP=8.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-apache-alpine
- name: Build and push 8.4 with Apache2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.alpine-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
ALPINE_VERSION=3.21
PHP_VERSION=84
PHP=8.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-apache-alpine
git.winteraccess.id/${{ gitea.repository }}:8-apache-alpine
git.winteraccess.id/${{ gitea.repository }}:apache-alpine

View File

@ -0,0 +1,76 @@
name: Build and push Nginx on alpine based container images
on:
push:
branches:
- master
jobs:
build:
name: Build nginx container images
runs-on: ubuntu-latest
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
strategy:
matrix:
flavors: ["cli", "full", "debug"]
version:
- os: "alpine"
os_version: "3.5"
php_version: "5.6"
php_ver_short: "5"
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Login to quay.io
uses: docker/login-action@v3
with:
registry: quay.io
username: ${{ vars.QUAY_USERNAME }}
password: ${{ secrets.QUAY_SECRET }}
# - name: Set up QEMU
# uses: docker/setup-qemu-action@v3
- name: Setup Docker buildx
uses: docker/setup-buildx-action@v3
- name: Build and push php on alpine base
uses: docker/build-push-action@v5
with:
push: true
context: .
file: Dockerfile.${{ matrix.version.os }}
build-args: |
OS_VERSION=${{ matrix.version.os }}
PHP_VERSION=${{ matrix.version.php_version }}
PHP_VER_SHORT=${{ matrix.version.php_ver_short }}
tags: |
quay.io/sindigilive/php:${{ matrix.version.php_version }}-${{ matrix.version.flavor }}-${{ matrix.version.os }}
# build-latest:
# name: Build latest nginx alpine based container images
# runs-on: ubuntu-latest
# needs:
# - build
# container:
# image: ghcr.io/catthehacker/ubuntu:act-latest
# steps:
# - name: Check out repository code
# uses: actions/checkout@v4
# - name: Login to quay.io
# uses: docker/login-action@v3
# with:
# registry: quay.io
# username: ${{ vars.QUAY_USERNAME }}
# password: ${{ secrets.QUAY_SECRET }}
# # - name: Set up QEMU
# # uses: docker/setup-qemu-action@v3
# - name: Setup Docker buildx
# uses: docker/setup-buildx-action@v3
# - name: Build and push latest nginx
# uses: docker/build-push-action@v5
# with:
# # platforms: linux/amd64,linux/arm64
# push: true
# context: .
# file: Dockerfile.alpine
# tags: |
# quay.io/sindigilive/nginx:alpine
# quay.io/sindigilive/nginx:latest

View File

@ -1,320 +0,0 @@
name: Build and Push ubi9 PHP Image
on:
push:
branches:
- master
jobs:
build:
name: Build and push ubi9 image
runs-on: ubuntu-latest
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=7.4
push: true
tags: |
aprimediet/php:7.4-ubi9
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=8.0
push: true
tags: |
aprimediet/php:8.0-ubi9
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=8.1
push: true
tags: |
aprimediet/php:8.1-ubi9
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=8.2
push: true
tags: |
aprimediet/php:8.2-ubi9
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=8.3
push: true
tags: |
aprimediet/php:8.3-ubi9
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
PHP_VERSION=8.4
push: true
tags: |
aprimediet/php:8.4-ubi9
aprimediet/php:8-ubi9
aprimediet/php:ubi9
build-micro:
name: Build and push ubi9-micro image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=7.4
push: true
tags: |
aprimediet/php:7.4-ubi9-micro
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=8.0
push: true
tags: |
aprimediet/php:8.0-ubi9-micro
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=8.1
push: true
tags: |
aprimediet/php:8.1-ubi9-micro
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=8.2
push: true
tags: |
aprimediet/php:8.2-ubi9-micro
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=8.3
push: true
tags: |
aprimediet/php:8.3-ubi9-micro
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
PHP_VERSION=8.4
push: true
tags: |
aprimediet/php:8.4-ubi9-micro
aprimediet/php:8-ubi9-micro
aprimediet/php:ubi9-micro
build-apache:
name: Build and push ubi9 apache image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=7.4
push: true
tags: |
aprimediet/php:7.4-apache-ubi9
aprimediet/php:7-apache-ubi9
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=8.0
push: true
tags: |
aprimediet/php:8.0-apache-ubi9
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=8.1
push: true
tags: |
aprimediet/php:8.1-apache-ubi9
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=8.2
push: true
tags: |
aprimediet/php:8.2-apache-ubi9
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=8.3
push: true
tags: |
aprimediet/php:8.3-apache-ubi9
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
PHP_VERSION=8.4
push: true
tags: |
aprimediet/php:8.4-apache-ubi9
aprimediet/php:8-apache-ubi9
aprimediet/php:apache-ubi9
build-apache-micro:
name: Build and push ubi9-micro image
runs-on: ubuntu-latest
needs:
- build
- build-micro
- build-apache
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: docker.io
username: aprimediet
password: ${{ secrets.DOCKER_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=7.4
push: true
tags: |
aprimediet/php:7.4-apache-ubi9-micro
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=8.0
push: true
tags: |
aprimediet/php:8.0-apache-ubi9-micro
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=8.1
push: true
tags: |
aprimediet/php:8.1-apache-ubi9-micro
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=8.2
push: true
tags: |
aprimediet/php:8.2-apache-ubi9-micro
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=8.3
push: true
tags: |
aprimediet/php:8.3-apache-ubi9-micro
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
PHP_VERSION=8.4
push: true
tags: |
aprimediet/php:8.4-apache-ubi9-micro
aprimediet/php:8-apache-ubi9-micro
aprimediet/php:apache-ubi9-micro

View File

@ -1,344 +0,0 @@
name: Build and Push ubi9 PHP Image
on:
push:
branches:
- master
jobs:
build:
name: Build and push ubi9 image to winter registry
runs-on: ubuntu-latest
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=7.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-ubi9
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.0
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-ubi9
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.1
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-ubi9
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-ubi9
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-ubi9
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-ubi9
git.winteraccess.id/${{ gitea.repository }}:8-ubi9
git.winteraccess.id/${{ gitea.repository }}:ubi9
build-micro:
name: Build and push ubi9-micro image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=7.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-ubi9-micro
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.0
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-ubi9-micro
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.1
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-ubi9-micro
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-ubi9-micro
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-ubi9-micro
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-ubi9-micro
git.winteraccess.id/${{ gitea.repository }}:8-ubi9-micro
git.winteraccess.id/${{ gitea.repository }}:ubi9-micro
build-apache:
name: Build and push ubi9 apache image
runs-on: ubuntu-latest
needs:
- build
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=7.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-apache-ubi9
git.winteraccess.id/${{ gitea.repository }}:7-apache-ubi9
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.0
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-apache-ubi9
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.1
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-apache-ubi9
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-apache-ubi9
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-apache-ubi9
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-apache-ubi9
git.winteraccess.id/${{ gitea.repository }}:8-apache-ubi9
git.winteraccess.id/${{ gitea.repository }}:apache-ubi9
build-apache-micro:
name: Build and push ubi9-micro image
runs-on: ubuntu-latest
needs:
- build
- build-micro
- build-apache
container:
image: ghcr.io/catthehacker/ubuntu:act-latest
steps:
- name: Check out repository code
uses: actions/checkout@v3
- name: Login to Docker Registry
uses: docker/login-action@v3
with:
registry: git.winteraccess.id
username: ${{ vars.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Build and push 7.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=7.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:7.4-apache-ubi9-micro
- name: Build and push 8.0
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.0
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.0-apache-ubi9-micro
- name: Build and push 8.1
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.1
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.1-apache-ubi9-micro
- name: Build and push 8.2
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.2
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.2-apache-ubi9-micro
- name: Build and push 8.3
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.3
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.3-apache-ubi9-micro
- name: Build and push 8.4
uses: docker/build-push-action@v5
with:
context: .
file: Dockerfile.ubi9-micro-apache
build-args: |
REGISTRY_URL=git.winteraccess.id/docker
PHP_VERSION=8.4
push: true
tags: |
git.winteraccess.id/${{ gitea.repository }}:8.4-apache-ubi9-micro
git.winteraccess.id/${{ gitea.repository }}:8-apache-ubi9-micro
git.winteraccess.id/${{ gitea.repository }}:apache-ubi9-micro

View File

@ -1,49 +0,0 @@
# PHP 5.6 == 3.5
ARG ALPINE_VERSION=3.5
FROM quay.io/sindigilive/alpine:${ALPINE_VERSION} AS builder
LABEL maintainer="<Muhamad Aditya Prima> map@sindigilive.com"
ARG PHP_VERSION=5.6
ARG PHP_SHORT_VER=5
ENV PHP_VERSION=${PHP_VERSION}
ENV PHP_SHORT_VER=${PHP_SHORT_VER}
WORKDIR /root
# INSTALL PHP APP
RUN mkdir -p /app ; \
apk add --update --no-cache \
php${PHP_SHORT_VER} php${PHP_SHORT_VER}-common ;
# CREATE SYMLINKS TO /usr/bin/php IN CASE IT IS NOT EXISTS
RUN ln -ns /usr/bin/php${PHP_SHORT_VER} /usr/bin/php ; exit 0
# CLEAN APK CACHES
RUN rm -vrf /var/cache/apk/*
FROM scratch
ARG PHP_VERSION=5.6
ARG PHP_SHORT_VER=5
ENV PHP_VERSION=${PHP_VERSION}
ENV PHP_SHORT_VER=${PHP_SHORT_VER}
LABEL maintainer="Muhamad Aditya Prima <map@sindigilive.com>"
LABEL name="php"
LABEL version="${PHP_VERSION}"
LABEL distribution-scope="public"
#labels for container catalog
LABEL summary="PHP ${PHP_VERSION} on alpine based container image"
LABEL description="Provide php on alpine based container base image"
LABEL io.k8s.description="Very small alpine linux container image"
LABEL io.k8s.display-name="PHP ${PHP_VERSION}"
COPY --from=builder / /
WORKDIR /app
STOPSIGNAL SIGQUIT
ENTRYPOINT ["/usr/bin/php", "-v"]

29
5/scripts/alpine-setup.sh Normal file
View File

@ -0,0 +1,29 @@
#!/bin/sh
PHP_LIST="bcmath,bz2,calendar,cgi,ctype,
curl,dba,dev,doc,
dom,embed,enchant,exif,ftp,
gd,gettext,gmp,iconv,imap,
intl,json,ldap,mailparse,mcrypt,
memcache,opcache,openssl,pcntl,pdo,
pear,pear-net_socket,phar,phpdbg,
phpmailer,posix,pspell,shmop,
snmp,soap,sockets,sysvmsg,sysvsem,
sysvshm,wddx,xcache,xml,xmlreader,
xmlrpc,xsl,zip,zlib"
PHP_DEPS=""
echo $FLAVOR
if [[ "$FLAVOR" == "debug" ]]; then
/sbin/apk add --update --no-cache php$PHP_VER_SHORT-dbg;
fi
if [ "$FLAVOR" == "full" ] || [ "$FLAVOR" == "debug" ]; then
for i in $(echo $PHP_LIST | tr "," "\n"); do
PHP_DEPS="${PHP_DEPS} php$PHP_VER_SHORT-$i ";
done
/sbin/apk add --update --no-cache $PHP_DEPS;

View File

@ -7,25 +7,61 @@
# PHP 8.2 == 3.18 # PHP 8.2 == 3.18
# PHP 8.3 == 3.19 # PHP 8.3 == 3.19
# PHP 8.4 == 3.21 # PHP 8.4 == 3.21
ARG REGISTRY_URL=docker.io/aprimediet ARG OS_VERSION=3.21
ARG ALPINE_VERSION=3.21
FROM ${REGISTRY_URL}/alpine:${ALPINE_VERSION} FROM quay.io/sindigilive/alpine:${OS_VERSION} AS builder
LABEL maintainer="<Muhamad Aditya Prima> aprimediet@gmail.com" LABEL maintainer="<Muhamad Aditya Prima> map@sindigilive.com"
ARG PHP_VERSION=84 ARG FLAVOR=cli
ARG PHP_VERSION=5.6
ARG PHP_VER_SHORT=5
ENV FLAVOR=${FLAVOR}
ENV PHP_VERSION=${PHP_VERSION} ENV PHP_VERSION=${PHP_VERSION}
ENV PHP_VER_SHORT=${PHP_VER_SHORT}
WORKDIR /root WORKDIR /root
# INSTALL PHP APP ADD 5/scripts/alpine-setup.sh /tmp/5-setup.sh
RUN --mount=type=cache,target=/var/cache/apk \
apk add --update php${PHP_VERSION} php${PHP_VERSION}-common
# CREATE SYMLINKS TO /usr/bin/php IN CASE IT IS NOT EXISTS # Create directory, and install required php app
RUN ln -ns /usr/bin/php${PHP_VERSION} /usr/bin/php; exit 0 RUN /bin/mkdir -p /app ; \
/sbin/apk add --update --no-cache \
php${PHP_VER_SHORT} php${PHP_VER_SHORT}-common \
php${PHP_VER_SHORT}-cli ; \
/bin/chmod +x /tmp/${PHP_VER_SHORT}-setup.sh; \
/bin/sh /tmp/${PHP_VER_SHORT}-setup.sh; \
/bin/rm -f /tmp/*.sh;
# Create symlinks to /usr/bin/php in case it doesn't exists
RUN ln -ns /usr/bin/php${PHP_VER_SHORT} /usr/bin/php ; exit 0
# CLEAN APK CACHES # CLEAN APK CACHES
RUN rm -vrf /var/cache/apk/* RUN rm -vrf /var/cache/apk/*
CMD ["/usr/bin/php"] FROM scratch
ARG PHP_VERSION=5.6
ARG PHP_VER_SHORT=5
ENV PHP_VERSION=${PHP_VERSION}
ENV PHP_VER_SHORT=${PHP_VER_SHORT}
LABEL maintainer="Muhamad Aditya Prima <map@sindigilive.com>"
LABEL name="php"
LABEL version="${PHP_VERSION}"
LABEL distribution-scope="public"
#labels for container catalog
LABEL summary="PHP ${PHP_VERSION} on alpine based container image"
LABEL description="Provide php on alpine based container base image"
LABEL io.k8s.description="Very small alpine linux container image"
LABEL io.k8s.display-name="PHP ${PHP_VERSION}"
COPY --from=builder / /
WORKDIR /app
STOPSIGNAL SIGQUIT
CMD ["/usr/bin/php", "-v"]