PHP runtime image built on UDX Worker with NGINX and PHP-FPM wired for /var/www.
Quick Start - Runtime - Development - Deployment - Rabbit CI
udx-worker-php extends udx/worker, published as usabilitydynamics/udx-worker, and keeps the worker runtime model while adding a PHP web stack:
- NGINX serves
/var/www. - PHP-FPM runs behind NGINX through a Unix socket.
- PHP CLI and common extensions are installed for application and automation workloads.
- Worker service definitions start both
php-fpmandnginx.
Use this image as a base for PHP applications, automation jobs, or deployment workflows that need the Worker runtime contract.
Requirements: Docker. Make is optional but recommended for local development.
Run the published image:
docker run -d \
--name my-php-app \
-p 8080:80 \
-v "$(pwd)/my-php-app:/var/www" \
usabilitydynamics/udx-worker-php:latestThen open http://localhost:8080.
Build and run locally:
git clone https://github.com/udx/worker-php.git
cd worker-php
make build
make run HOST_PORT=8080
make log FOLLOW_LOGS=truemake run uses defaults from Makefile.variables, including ./src/scripts:/var/www, .env, and container port 80.
This image does not require default environment variables. Runtime environment values and secret references belong in worker.yaml or the target platform.
The runtime contract is defined by the Dockerfile and the configs copied into the image:
Dockerfilepins the base Worker image and Ubuntu package versions.etc/configs/nginx/defines the NGINX server and PHP FastCGI integration.etc/configs/php/defines PHP-FPM process and pool behavior.etc/configs/worker/services.yamldeclares Worker-managed services.
/var/www is both the declared volume and working directory. NGINX sends PHP requests to the PHP-FPM Unix socket configured during the image build.
Common commands:
make help
make build
make run HOST_PORT=8080
make exec
make log
make cleanRun all validation:
make testRun only the container test suite against an already built image:
make run-all-testsRun one test script:
make run-test TEST_SCRIPT=10_nginx_test.phpCurrent tests live in src/tests/ and cover NGINX HTTP response, PHP runtime availability, PHP CLI execution, and write permissions under /var/www.
Deployment uses the host-native tool for the target environment. Mount application code at /var/www and publish container port 80 through the platform.
The GitHub release pipeline is declared in .github/workflows/docker-ops.yml and delegates Docker publishing to udx/reusable-workflows.
For dependency upgrades, include the changed base image/packages and the local verification result in the PR description.
worker.yaml follows the base Worker config contract for runtime config.env values and config.secrets references. Deployment environment variables override values declared in worker.yaml.
See docs/worker-config.md for the local config reference.
References:
- https://github.com/udx/worker/blob/latest/docs/config.md
- https://github.com/udx/worker/blob/latest/docs/secrets.md
- https://github.com/udx/worker/blob/latest/docs/deployment.md
Rabbit-facing repo context lives in .rabbit/. This image repo publishes the worker-php Docker image; it does not own tenant-specific Rabbit lifecycle manifests.
See .rabbit/README.md for Rabbit CI entry points, delivery notes, and generated repo context handling.
- Docker Hub: https://hub.docker.com/r/usabilitydynamics/udx-worker-php
- Source: https://github.com/udx/worker-php
- Base runtime docs: https://github.com/udx/worker/tree/latest/docs
MIT. See LICENSE.