Skip to content

Latest commit

 

History

History
58 lines (46 loc) · 4.22 KB

README.md

File metadata and controls

58 lines (46 loc) · 4.22 KB

Documentation

Documentation for the webdevops/* Docker images. It describes the images as they are built from this repository.

Images

Image Purpose
webdevops/php, webdevops/php-dev PHP-FPM
webdevops/php-nginx, webdevops/php-nginx-dev PHP-FPM with Nginx
webdevops/php-apache, webdevops/php-apache-dev PHP-FPM with Apache
webdevops/bootstrap, webdevops/base, webdevops/base-app Base images for your own images
webdevops/toolbox Build helper, not meant to run. Stores the baselayout scripts (apt-install, apk-install, docker-image-cleanup, docker-run-bootstrap, generate-locales and more), go-replace and gosu under /baselayout. bootstrap and php copy them from there with COPY --from=webdevops/toolbox. In toolbox itself only go-replace is on the PATH.
webdevops/dockerfile-build-env Build environment for this repository, based on base-app:ubuntu-22.04. The CI builds and tests the images in it, see Building in CI.

webdevops/nginx, webdevops/apache, the alpine tags of webdevops/bootstrap, webdevops/base and webdevops/base-app, as well as webdevops/storage, webdevops/vsftp and webdevops/ssh are no longer built, and webdevops/php-official is deprecated. Replacing discontinued images shows what to use instead.

Platforms and updates

  • The images are on Docker Hub for linux/amd64 and linux/arm64. Docker pulls the one that matches your machine.

  • The CI rebuilds all tags every night. The build starts at 00:00 UTC and runs without the build cache, so packages and extensions are installed fresh. A tag such as 8.5 therefore points to a new image after every nightly build.

  • A new PHP release does not wait for the night: every hour the CI compares the PHP version of the official php images with that of webdevops/php and webdevops/php-nginx, and starts the build as soon as an official image has a newer PHP. Such a build uses the build cache; a changed base image rebuilds every layer above it.

  • To keep an image unchanged, pin it by digest. Docker then uses the digest; the tag in front of it is only for readers:

    services:
      app:
        image: webdevops/php-nginx:8.5@sha256:<digest>

    docker buildx imagetools inspect webdevops/php-nginx:8.5 prints the current digest in the line Digest:. Update the pinned digest regularly, or you miss security updates.

Topics

How the images build on each other

flowchart LR
  ubuntu["ubuntu:22.04"] --> bootstrap["webdevops/bootstrap"]
  bootstrap --> base["webdevops/base"]
  base --> baseapp["webdevops/base-app"]
  officialphp["php:VERSION-fpm-bookworm / php:8.6-fpm-trixie / php:VERSION-fpm-alpine"] --> php["webdevops/php"]
  php --> phpdev["webdevops/php-dev"]
  php --> phpnginx["webdevops/php-nginx"]
  php --> phpapache["webdevops/php-apache"]
  phpnginx --> phpnginxdev["webdevops/php-nginx-dev"]
  phpapache --> phpapachedev["webdevops/php-apache-dev"]
  alpine["alpine:latest"] --> toolbox["webdevops/toolbox"]
  baseapp --> buildenv["webdevops/dockerfile-build-env"]
  toolbox -. "COPY --from" .-> bootstrap
  toolbox -. "COPY --from" .-> php
Loading