This project provides optimized Docker images to run PHP applications with the Nginx web server.
It is based on php-fpm-docker and php-base-docker, supporting multiple PHP versions and architectures.
We also provide an AI generated DeepWiki Page with more technical information.
💡 For a complete list of available images, please visit the PHP System Docs page.
Each image is tagged with the PHP version. For example:
fbraz3/php-nginx:8.4
for PHP 8.4fbraz3/php-nginx:8.4-phalcon
for PHP 8.4 with Phalcon extension
Multi-architecture images (amd64
and arm64
) are also available.
This project supports different flavors
to meet specific needs:
Vanilla
: Standard image with PHP and Nginx.Phalcon
: Includes support for the Phalcon framework.
To run a PHP application with Nginx, use the following command:
docker run --name my-app -v $(pwd):/app/public -p 80:80 -d fbraz3/php-nginx:8.4
Replace 8.4
with the desired PHP version.
You can test the image with the following command:
curl http://127.0.0.1/
Ensure the current directory contains an index.php
or index.html
file.
Refer to the php-fpm-docker documentation to learn how to manage PHP directives using environment variables.
To configure cronjobs
, see the corresponding section in the php-fpm-docker documentation.
To configure email sending, refer to the php-base-docker documentation.
Contributions are welcome! Feel free to open issues or submit pull requests to improve the project.
Please visit the CONTRIBUTING.md file for guidelines on how to contribute to this project.
I spend a lot of time and effort maintaining this project. If you find it useful, consider supporting me with a donation:
This project is licensed under the Apache License 2.0, so you can use it for personal and commercial projects. However, please note that the images are provided "as is" without any warranty or guarantee of any kind. Use them at your own risk.