diff --git a/.gitea/workflows/alpine-dockerio.yaml b/.gitea/workflows/alpine-dockerio.yaml index 48823d4..f904bbf 100644 --- a/.gitea/workflows/alpine-dockerio.yaml +++ b/.gitea/workflows/alpine-dockerio.yaml @@ -25,7 +25,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.5 PHP_VERSION=5 push: true @@ -37,7 +36,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.9 PHP_VERSION=7 push: true @@ -49,7 +47,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.10 PHP_VERSION=7 push: true @@ -61,7 +58,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.13 PHP_VERSION=7 push: true @@ -73,7 +69,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.16 PHP_VERSION=8 push: true @@ -85,7 +80,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.18 PHP_VERSION=81 push: true @@ -97,7 +91,6 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.18 PHP_VERSION=82 push: true @@ -109,14 +102,24 @@ jobs: context: . file: Dockerfile.alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.19 PHP_VERSION=83 push: true tags: | - aprimediet/php:8-alpine aprimediet/php:8.3-alpine - aprimediet/php:latest-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 @@ -139,7 +142,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.5 PHP_VERSION=5 PHP=5.6 @@ -152,7 +154,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.9 PHP_VERSION=7 PHP=7.2 @@ -165,7 +166,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.10 PHP_VERSION=7 PHP=7.3 @@ -178,7 +178,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.13 PHP_VERSION=7 PHP=7.4 @@ -191,7 +190,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.16 PHP_VERSION=8 PHP=8.0 @@ -204,7 +202,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.18 PHP_VERSION=81 PHP=8.1 @@ -217,7 +214,6 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.18 PHP_VERSION=82 PHP=8.2 @@ -230,12 +226,22 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | - REGISTRY_URL=docker.io/aprimediet ALPINE_VERSION=3.19 PHP_VERSION=83 PHP=8.3 push: true tags: | - aprimediet/php:8-apache-alpine aprimediet/php:8.3-apache-alpine - aprimediet/php:latest-apache-alpine \ No newline at end of file + - name: Build and push 8.3 with Apache2 + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.apache-alpine + build-args: | + ALPINE_VERSION=3.21 + PHP_VERSION=84 + PHP=8.4 + push: true + tags: | + aprimediet/php:8-apache-alpine + aprimediet/php:8.4-apache-alpine \ No newline at end of file diff --git a/.gitea/workflows/alpine-winter.yaml b/.gitea/workflows/alpine-winter.yaml index f8aa343..e9e45f6 100644 --- a/.gitea/workflows/alpine-winter.yaml +++ b/.gitea/workflows/alpine-winter.yaml @@ -17,14 +17,15 @@ jobs: uses: docker/login-action@v3 with: registry: git.winteraccess.id - username: aditya.prima - password: ${{ secrets.PATOKEN }} + 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 @@ -36,6 +37,7 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.9 PHP_VERSION=7 push: true @@ -47,6 +49,7 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.10 PHP_VERSION=7 push: true @@ -58,6 +61,7 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.13 PHP_VERSION=7 push: true @@ -69,10 +73,12 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.16 PHP_VERSION=8 push: true tags: | + REGISTRY_URL=git.winteraccess.id/docker git.winteraccess.id/${{ gitea.repository }}:8.0-alpine - name: Build and push 8.1 uses: docker/build-push-action@v5 @@ -80,6 +86,7 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.18 PHP_VERSION=81 push: true @@ -91,6 +98,7 @@ jobs: context: . file: Dockerfile.alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.18 PHP_VERSION=82 push: true @@ -102,12 +110,24 @@ jobs: 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 - git.winteraccess.id/${{ gitea.repository }}:latest-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 build-apache: name: Build and push apache image runs-on: ubuntu-latest @@ -122,14 +142,15 @@ jobs: uses: docker/login-action@v3 with: registry: git.winteraccess.id - username: aditya.prima - password: ${{ secrets.PATOKEN }} + 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.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.5 PHP_VERSION=5 PHP=5.6 @@ -142,11 +163,13 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.9 PHP_VERSION=7 PHP=7.2 push: true tags: | + REGISTRY_URL=git.winteraccess.id/docker git.winteraccess.id/${{ gitea.repository }}:7.2-apache-alpine - name: Build and push 7.3 with Apache2 uses: docker/build-push-action@v5 @@ -154,6 +177,7 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.10 PHP_VERSION=7 PHP=7.3 @@ -166,6 +190,7 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.13 PHP_VERSION=7 PHP=7.4 @@ -178,6 +203,7 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.16 PHP_VERSION=8 PHP=8.0 @@ -190,6 +216,7 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.18 PHP_VERSION=81 PHP=8.1 @@ -202,6 +229,7 @@ jobs: context: . file: Dockerfile.apache-alpine build-args: | + REGISTRY_URL=git.winteraccess.id/docker ALPINE_VERSION=3.18 PHP_VERSION=82 PHP=8.2 @@ -214,11 +242,24 @@ jobs: context: . file: Dockerfile.apache-alpine 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-apache-alpine git.winteraccess.id/${{ gitea.repository }}:8.3-apache-alpine - git.winteraccess.id/${{ gitea.repository }}:latest-apache-alpine \ No newline at end of file + - name: Build and push 8.4 with Apache2 + uses: docker/build-push-action@v5 + with: + context: . + file: Dockerfile.apache-alpine + 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-apache-alpine + git.winteraccess.id/${{ gitea.repository }}:8.4-apache-alpine \ No newline at end of file diff --git a/.gitea/workflows/ubuntu-dockerio.yaml b/.gitea/workflows/ubuntu-dockerio.yaml deleted file mode 100644 index f9e6299..0000000 --- a/.gitea/workflows/ubuntu-dockerio.yaml +++ /dev/null @@ -1,116 +0,0 @@ -name: Build and Push Ubuntu PHP 8.3 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.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=5.6 - push: true - tags: | - aprimediet/php:5.6-ubuntu - aprimediet/php:5.6 - - name: Build and push 7.2 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=7.2 - push: true - tags: | - aprimediet/php:7.2-ubuntu - aprimediet/php:7.2 - - name: Build and push 7.4 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=7.4 - push: true - tags: | - aprimediet/php:7.4-ubuntu - aprimediet/php:7.4 - - name: Build and push 8.0 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=8.0 - push: true - tags: | - aprimediet/php:8.0-ubuntu - aprimediet/php:8.0 - - name: Build and push 8.1 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=8.1 - push: true - tags: | - aprimediet/php:8.1-ubuntu - aprimediet/php:8.1 - - name: Build and push 8.2 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=8.2 - push: true - tags: | - aprimediet/php:8.2-ubuntu - aprimediet/php:8.2 - - name: Build and push 8.3 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - REGISTRY_URL=docker.io/aprimediet - UBUNTU_VERSION=jammy - PHP_VERSION=8.3 - push: true - tags: | - aprimediet/php:8.3-ubuntu - aprimediet/php:8.3 - aprimediet/php:8 - aprimediet/php:latest-ubuntu - aprimediet/php:latest - \ No newline at end of file diff --git a/.gitea/workflows/ubuntu-winter.yaml b/.gitea/workflows/ubuntu-winter.yaml deleted file mode 100644 index caf76cd..0000000 --- a/.gitea/workflows/ubuntu-winter.yaml +++ /dev/null @@ -1,108 +0,0 @@ -name: Build and Push Ubuntu PHP 8.3 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: git.winteraccess.id - username: aditya.prima - password: ${{ secrets.PATOKEN }} - - name: Build and push 5.6 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=5.6 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:5.6-ubuntu - git.winteraccess.id/${{ gitea.repository }}:5.6 - - name: Build and push 7.2 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=7.2 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:7.2-ubuntu - git.winteraccess.id/${{ gitea.repository }}:7.2 - - name: Build and push 7.4 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=7.4 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:7.4-ubuntu - git.winteraccess.id/${{ gitea.repository }}:7.4 - - name: Build and push 8.0 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=8.0 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:8.0-ubuntu - git.winteraccess.id/${{ gitea.repository }}:8.0 - - name: Build and push 8.1 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=8.1 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:8.1-ubuntu - git.winteraccess.id/${{ gitea.repository }}:8.1 - - name: Build and push 8.2 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=8.2 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:8.2-ubuntu - git.winteraccess.id/${{ gitea.repository }}:8.2 - - name: Build and push 8.3 - uses: docker/build-push-action@v5 - with: - context: . - file: Dockerfile.ubuntu - build-args: | - UBUNTU_VERSION=jammy - PHP_VERSION=8.3 - push: true - tags: | - git.winteraccess.id/${{ gitea.repository }}:8.3-ubuntu - git.winteraccess.id/${{ gitea.repository }}:8.3 - git.winteraccess.id/${{ gitea.repository }}:latest-ubuntu - git.winteraccess.id/${{ gitea.repository }}:latest - \ No newline at end of file diff --git a/Dockerfile.alpine b/Dockerfile.alpine index 6776b0f..1791878 100644 --- a/Dockerfile.alpine +++ b/Dockerfile.alpine @@ -6,7 +6,8 @@ # PHP 8.1 == 3.18 # PHP 8.2 == 3.18 # PHP 8.3 == 3.19 -ARG REGISTRY_URL=git.winteraccess.id/docker +# PHP 8.4 == 3.21 +ARG REGISTRY_URL=docker.io/aprimediet ARG ALPINE_VERSION=3.19 FROM ${REGISTRY_URL}/alpine:${ALPINE_VERSION} diff --git a/Dockerfile.apache-alpine b/Dockerfile.apache-alpine index 81e270c..eb1d1de 100644 --- a/Dockerfile.apache-alpine +++ b/Dockerfile.apache-alpine @@ -15,7 +15,8 @@ ENV PHP_MEMORY_LIMIT=256M WORKDIR /tmp # SETUP APACHE2 USER -RUN addgroup -g 10001 apache && adduser -D -u 10001 -G apache -s /bin/sh -h ${APP_DIR} apache +RUN addgroup -g 10001 apache && \ + adduser -D -u 10001 -G apache -s /bin/sh -h ${APP_DIR} apache # INSTALL APACHE2 RUN --mount=type=cache,target=/var/cache/apk \ diff --git a/Dockerfile.ubi9 b/Dockerfile.ubi9 new file mode 100644 index 0000000..cbf63be --- /dev/null +++ b/Dockerfile.ubi9 @@ -0,0 +1,20 @@ +ARG REGISTRY_URL=docker.io/aprimediet +ARG UBI_VERSION=9.5 + +FROM ${REGISTRY_URL}/ubi9:${UBI_VERSION} AS builder +LABEL maintainer=" aprimediet@gmail.com" + +ARG PHP_VERSION=8.3 +ENV PHP_VERSION=${PHP_VERSION} + +USER root + +# Update packages, Install Remi PHP Repository +RUN dnf -y update && \ + dnf -y install https://rpms.remirepo.net/enterprise/remi-release-${UBI_VERSION}.rpm && \ + dnf -y install yum-utils && \ + dnf -y module reset php && \ + dnf -y module install php:remi-${PHP_VERSION} && \ + dnf -y autoremove && dnf -y clean all + +CMD ["/usr/bin/php"] \ No newline at end of file diff --git a/Dockerfile.ubi9-micro b/Dockerfile.ubi9-micro new file mode 100644 index 0000000..7445e5f --- /dev/null +++ b/Dockerfile.ubi9-micro @@ -0,0 +1,49 @@ +ARG REGISTRY_URL=docker.io/aprimediet +ARG PHP_VERSION=8.4 +ARG UBI_VERSION=9.5 + +FROM ${REGISTRY_URL}/php:${PHP_VERSION}-ubi9 AS builder +LABEL maintainer=" aprimediet@gmail.com" + +FROM ${REGISTRY_URL}/ubi9:${UBI_VERSION}-micro AS runtime +LABEL maintainer=" aprimediet@gmail.com" + +ARG PHP_VERSION=8.4 +ENV PHP_VERSION=${PHP_VERSION} + +USER root + +# Copy required libs +COPY --from=builder /usr/lib64/fipscheck /usr/lib64/fipscheck +COPY --from=builder /usr/lib64/libbz2* /usr/lib64 +COPY --from=builder /usr/lib64/libcrypt* /usr/lib64 +COPY --from=builder /usr/lib64/libcom_err* /usr/lib64 +COPY --from=builder /usr/lib64/libcurl* /usr/lib64 +COPY --from=builder /usr/lib64/libedit* /usr/lib64 +COPY --from=builder /usr/lib64/libexslt* /usr/lib64 +COPY --from=builder /usr/lib64/libgssapi* /usr/lib64 +COPY --from=builder /usr/lib64/libkeyutils* /usr/lib64 +COPY --from=builder /usr/lib64/libkrb5* /usr/lib64 +COPY --from=builder /usr/lib64/libk5crypto* /usr/lib64 +COPY --from=builder /usr/lib64/liblzma* /usr/lib64 +COPY --from=builder /usr/lib64/libnghttp2* /usr/lib64 +COPY --from=builder /usr/lib64/libonig* /usr/lib64 +COPY --from=builder /usr/lib64/libssl* /usr/lib64 +COPY --from=builder /usr/lib64/libxml* /usr/lib64 +COPY --from=builder /usr/lib64/libxslt* /usr/lib64 +COPY --from=builder /usr/lib64/libz* /usr/lib64 + +# Copy PHP Configuration +COPY --from=builder /etc/php.ini /etc/php.ini +COPY --from=builder /etc/php.d /etc/php.d + +# Copy PHP Libs +COPY --from=builder /usr/lib64/php /usr/lib64/php +COPY --from=builder /var/lib/php /var/lib/php + +# Copy Binaries +COPY --from=builder /usr/bin/php /usr/bin/php +COPY --from=builder /usr/bin/php-cgi /usr/bin/php-cgi +COPY --from=builder /usr/bin/phpize /usr/bin/phpize + +CMD ["/usr/bin/php"] \ No newline at end of file