Full-featured PHP-FPM with 40+ extensions, Node.js, Composer, SSH server and media processing.
5.0K
A comprehensive PHP-FPM image based on the official php:X.Y-fpm (Debian Bookworm), pre-loaded with a wide range of PHP extensions, system tools, Node.js, and Composer — ready for production and development use.
docker pull christinloehner/php-fpm:8.4-fpm
docker pull christinloehner/php-fpm:8.5-fpm
docker pull christinloehner/php-fpm:latest
This php images does contain openssh-server and composer. The openssh-server is for doing automated deployments directly into the containers. You can fire this up by using the following docker-compose.yml
services:
php:
image: christinloehner/php-fpm:latest
environment:
TZ: "${TZ}"
restart: unless-stopped
volumes:
- ./web:/config
- ./home:/home/web
- ./tmp:/var/www/tmp
- /etc/localtime:/etc/localtime:ro
ssh:
image: christinloehner/php-fpm:latest
command: "/usr/sbin/sshd -D"
environment:
TZ: "${TZ}"
depends_on:
- php
ports:
- 22001:22/tcp
volumes:
- ./sshd:/etc/ssh
- ./home:/home/web
- ./web:/config:z
- /etc/localtime:/etc/localtime:ro
restart: unless-stopped
| Tag | PHP Version | Node.js | Status |
|---|---|---|---|
latest | 8.5 | 24.x LTS | Stable |
8.5-fpm | 8.5 | 24.x LTS | Stable |
8.4-fpm | 8.4 | 22.x LTS | Stable |
| Extension | Description |
|---|---|
gd | Image processing (FreeType, JPEG, WebP, XPM) |
imap | IMAP/POP3/NNTP mailbox access |
ldap | LDAP directory access |
pdo_mysql / mysqli | MySQL / MariaDB |
pdo_pgsql / pgsql | PostgreSQL |
pdo_sqlite / sqlite3 | SQLite (statically compiled) |
opcache | Opcode cache (pre-configured) |
bcmath | Arbitrary precision mathematics |
bz2 | Bzip2 compression |
calendar | Calendar conversion |
curl | HTTP client |
dba | Database abstraction layer |
enchant | Spell checking |
exif | EXIF metadata from images |
ftp | FTP client |
gettext | NLS message catalogues |
gmp | GNU Multiple Precision |
intl | Internationalization |
mbstring | Multibyte string handling |
pcntl | Process control |
posix | POSIX functions |
readline | Readline (statically compiled) |
simplexml | SimpleXML |
shmop | Shared memory |
snmp | SNMP protocol |
soap | SOAP web services |
sockets | Low-level socket access |
sysvmsg / sysvsem / sysvshm | System V IPC |
tidy | HTML tidy |
xsl | XSL transformations |
zip | ZIP archives |
| Extension | Description |
|---|---|
apcu | In-memory user data cache |
igbinary | Binary serializer (faster alternative to PHP's native) |
imagick | ImageMagick binding (built from latest master) |
memcache / memcached | Memcached client |
mongodb | MongoDB driver |
redis | Redis client |
xdebug | Debugger and profiler |
yaml | YAML parsing and emitting |
opcache.memory_consumption=256
opcache.interned_strings_buffer=8
opcache.max_accelerated_files=20000
opcache.revalidate_freq=5
opcache.fast_shutdown=1
opcache.enable_cli=1
Development & Utilities
git, curl, wget, vim, nano, mc, screen, sudo, jqrsync, zstd, unzip, gnupg, ca-certificatesbuild-essential, bison, flexMedia Processing
ffmpeg, ffmpegthumbnailer — Video processing and thumbnail generationimagemagick, graphicsmagick — Image conversion and manipulationjpegoptim, optipng, pngcrush, webp — Image optimizationPDF & Documents
ghostscript — PostScript/PDF interpreterpdftk-java — PDF toolkitServer & Infrastructure
openssh-server — SSH server (host keys are removed and regenerated at container start)mariadb-client — MySQL/MariaDB CLImsmtp + msmtp-mta — Lightweight mail transport agentcron — Cron daemonsnmp — SNMP toolslogrotate — Log rotationphp-fpm-healthcheck — FPM health check endpointNode.js is installed via NVM and available system-wide:
node, nodejs, npm, npx
Node.js LTS is set as default and available to all users via PATH.
Composer (latest stable) is installed at /usr/local/bin/composer.
A dedicated system user is pre-created for running web applications:
| Property | Value |
|---|---|
| Username | web |
| UID | 1000 |
| Home | /home/web |
| Groups | web, www-data |
| Shell | /bin/bash |
| umask | 002 |
The /config directory (working directory) is owned by web:web and group-writable.
Pre-generated locales:
de_DE.UTF-8en_US.UTF-8ENTRYPOINT ["php-entrypoint"]
CMD ["php-fpm"]
WORKDIR /config
| Version | Notable Differences |
|---|---|
| 8.5 | opcache statically compiled; memcached extension instead of memcache |
| 8.4 | pspell removed from PHP core; imap built via mlocati installer; Node.js via NVM |
Content type
Image
Digest
sha256:02d73dc98…
Size
748.4 MB
Last updated
3 months ago
docker pull christinloehner/php-fpm