Proyek
Lihat di GitHub
urre/wordpress-nginx-docker-compose
Tentang
Jalankan WordPress dengan nginx menggunakan Docker Compose.
Sistem dan infrastrukturPertumbuhan bintang terukur
- dalam 24 jam
- 0
- dalam 7 hari
- 0
- dalam 15 hari
- 0
- dalam 1 bulan
- Mengumpulkan riwayat
Perubahan bersih pada periode yang tumpang tindih, bukan total harian. Pengukuran yang belum tersedia dibiarkan kosong. Bintang menunjukkan perhatian, bukan kualitas.
README.md
AsliDocker Compose and WordPress
Use WordPress locally with Docker using Docker compose
Contents
- A
Dockerfilefor extending a base image and using a custom Docker image with an automated build on Docker Hub - PHP 8.3
- Custom domain and HTTPS support. So you can use for example https://myapp.local
- Custom nginx config in
./nginx - Custom PHP
php.iniconfig in./config - Volumes for
nginx,wordpressandmariadb - Composer - dependency manager for PHP
- Bedrock - modern development tools, easier configuration, and an improved secured folder structure for WordPress
- WP-CLI - WP-CLI is the command-line interface for WordPress.
- Mailpit - An email testing tool for developers. Catches all outgoing email and lets you view it in a web UI at http://127.0.0.1:8025.
- PhpMyAdmin - free and open source administration tool for MySQL and MariaDB
- PhpMyAdmin config in
./config
- PhpMyAdmin config in
- CLI script to create a SSL certificate using mkcert
Versions
| Component | Version |
|---|---|
| PHP | 8.3 (PHP-FPM, via the custom base image) |
| nginx | 1.27-alpine |
| MariaDB | 11.4 LTS |
| phpMyAdmin | 5.2 |
| Mailpit | latest (axllent/mailpit) |
| Composer | latest |
| WP-CLI | latest |
| WordPress | managed via Composer/Bedrock (roots/wordpress) |
The custom base image is multi-arch
(linux/amd64 + linux/arm64), so it runs natively on both Intel and Apple Silicon.
Instructions and help
See the new Wiki
Security
Found a security issue? Please don't open a public issue — see SECURITY.md for how to report it privately. Note that this is a local development environment and is not intended to be exposed to the public internet or used in production as-is.
Changelog
2026-07-24
- Modernized the stack: dropped the obsolete Compose
versionkey, pinned image tags, upgraded MariaDB 10.7 → 11.4 LTS,nginx→1.27-alpine, andphpMyAdmin→5.2. - Replaced the archived MailHog with the maintained Mailpit (same
8025/1025ports). - Hardened nginx: TLS 1.2/1.3 only (dropped TLSv1/1.1), modern ciphers,
http2 on;directive, and added security headers. - Modernized CI:
actions/checkout@v4, a PHP 8.1–8.3 matrix, Composer caching,composer validate, and runs on pull requests. - Added
SECURITY.md,CLAUDE.md, and an expandeddependabot.yml(Composer, Docker, GitHub Actions, npm). - Upgraded PHP 8.1 → 8.3 via a rebuilt, multi-arch base image (
linux/amd64+linux/arm64), which runs natively on Apple Silicon (fixes the ARM emulation issue). - Bumped
composer/installersto v2 (removes the PHP 8.1 deprecation notice).
2024-05-28
- Update Composer to use PHP 8.1
- Added a GitHub Wiki for instructions
2022-05-28
- Use PHP 8.1 Dockerfile is updated.
2022-05-28
2022-05-28
- Updated the Docker image to use PHP 8
2021-08-04
- Updated to WordPress 5.8.0
2021-03-16
- Changed root
.env-exampleto.env.exampleto match the git ignore patterns. Thanks @scottnunemacher
2021-03-05
- Clarify steps in the readme
2021-03-02
- Fixed a misstake so instead of
./src/.env-example, it should be./src/.env.example. - Redirect HTTP to HTTPS. Thanks @humblecoder
2021-01-02
- Use
NGINX_ENVSUBST_TEMPLATE_SUFFIX. Use a template and better substution of ENV variables in nginx config.
2020-10-04
- Added mariadb-client (Solves #54)
2020-09-15
- Updated Bedrock. Update WordPress to 5.5.1 and other composer updates.
2020-07-12
- Added Mailhog. Thanks @mortensassi
2020-05-03
- Added nginx gzip compression
2020-04-19
- Added Windows support for creating SSH cert, trusting it and setting up the host file entry. Thanks to @styssi
2020-04-12
- Remove port number from
DB_HOST. Generated database connection error in macOS Catalina. Thanks to @nirvanadev - Add missing ENV variable from mariadb Thanks to @vonwa
2020-03-26
- Added phpMyAdmin config.Thanks to @titoffanton
2020-02-06
- Readme improvements. Explain
/etc/hostsbetter
2020-01-30
- Use
Entrypointcommand in Docker Compose to replace the domain name in the nginx config. Removing the need to manually edit the domain name in the nginx conf. Now using the.envvalueDOMAIN - Added APP_NAME in
.env-exampleThanks to @Dave3o3
2020-01-11
- Added
.envsupport for specifying your own app name, domain etc in Docker and cli scripts. - Added phpMyAdmin. Visit http://127.0.0.1:8080/
2019-08-02
- Added Linux support. Thanks to @faysal-ishtiaq.
Jelajahi proyek terkait
Memuat…