Skip to content

About

PHP docker container image for WordPress

Topics

Resources

Stars

33 stars

Watchers

4 watching

Forks

Repository files navigation

PHP for WordPress Docker Container Image

Build Status Docker Pulls Docker Stars

Docker Images

Use image revision tags such as wodby/wordpress-php:8.5-rN to select a Wodby image revision. Major and minor tags use the repository release number, starting at r0. Full-version tags such as wodby/wordpress-php:8.5.10-r0 start at r0 for each exact upstream version. Every published versioned revision tag has a matching annotated Git tag pointing to its release commit. Existing tags remain available after support for their major or minor version ends. See release tags for available revisions and the image revision policy for upgrade guidance. Previously published image tags remain available.

Overview:

Supported tags and respective Dockerfile links:

All images built for linux/amd64 and linux/arm64

Tools

This image comes with WP CLI version 2.12.0

Environment Variables

See at wodby/php. In addition:

Variable Default Description
WP_DISALLOW_FILE_MODS Any value sets DISALLOW_FILE_MODS: no plugin and theme installs, updates or file editor in wp-admin
WP_AUTOMATIC_UPDATER_DISABLED Any value sets AUTOMATIC_UPDATER_DISABLED: no background updates

Set both when the code is deployed as an image and cannot be changed at runtime.

WordPress core in a subdirectory

A Composer project can install WordPress core in the wp subdirectory of the web root and keep its themes, plugins and uploads in wp-content next to it, so that core installs and updates never delete them. When wp/wp-settings.php exists in the web root, the generated configuration points WP_SITEURL to /wp and WP_CONTENT_DIR and WP_CONTENT_URL to the wp-content directory of the web root. The web root then needs an index.php that loads wp/wp-blog-header.php, and WP-CLI commands take --path=<web root>/wp.

Orchestration Actions

Usage:

make COMMAND [params ...]
 
commands:
    duplicator-import source
    init-wordpress   
    cache-clear
    
default params values:
    target all
    is_hash 0 

See wodby/php for all actions

Complete WordPress Stack

See Docker4WordPress.

Building with pinned base images

Build with the Makefile to use the base image digests in base-images.mk. Local builds and CI resolve the same version and variant to the same multi-platform image. A version without a pin fails before the build starts.

When adding a supported base version or variant, add its image index digest to base-images.mk. For a custom build, override BASE_IMAGE with a complete repository:tag@sha256:... reference.

About

PHP docker container image for WordPress

Topics

Resources

Stars

33 stars

Watchers

4 watching

Forks

Releases

Packages

Used by

Contributors

Languages