{"id":20663235,"url":"https://github.com/sitepilot/docker-php","last_synced_at":"2026-05-05T10:32:08.031Z","repository":{"id":200967237,"uuid":"704087067","full_name":"sitepilot/docker-php","owner":"sitepilot","description":"Docker PHP is a collection of optimized and extensible container images for running PHP applications in production.","archived":false,"fork":false,"pushed_at":"2024-03-06T21:15:40.000Z","size":52,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"1.x","last_synced_at":"2025-01-17T12:29:25.128Z","etag":null,"topics":["docker","nginx","openlitespeed","php","php-cli","php-fpm","ubuntu"],"latest_commit_sha":null,"homepage":"https://sitepilot.io","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sitepilot.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-10-12T14:04:58.000Z","updated_at":"2024-02-06T09:04:08.000Z","dependencies_parsed_at":"2024-02-28T16:51:19.304Z","dependency_job_id":null,"html_url":"https://github.com/sitepilot/docker-php","commit_stats":null,"previous_names":["sitepilot/docker-php"],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitepilot%2Fdocker-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitepilot%2Fdocker-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitepilot%2Fdocker-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sitepilot%2Fdocker-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sitepilot","download_url":"https://codeload.github.com/sitepilot/docker-php/tar.gz/refs/heads/1.x","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242821486,"owners_count":20190654,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","nginx","openlitespeed","php","php-cli","php-fpm","ubuntu"],"created_at":"2024-11-16T19:17:05.692Z","updated_at":"2025-12-07T10:04:56.396Z","avatar_url":"https://github.com/sitepilot.png","language":"Dockerfile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Docker PHP\n\nDocker PHP is a collection of optimized and extensible container images for running PHP applications in production.\n\nAll images are based on our [Docker Runtime](https://github.com/sitepilot/docker-runtime) image, an optimized and\nextensible Ubuntu container image.\n\n## Usage\n\nThis repository creates several variations of Docker images, enabling you to select precisely what you require. Just\nutilize this image naming pattern in any of your projects:\n\n```bash\nghcr.io/sitepilot/php-{{variation-name}}:{{php-version}}\n```\n\nFor example, if you wish to run **PHP 8.3** with **FPM** \u0026 **NGINX**, use the following image name:\n\n```bash\nghcr.io/sitepilot/php-nginx:8.3\n```\n\n### Customization\n\nTo use this image as a base image and avoid potential breaking changes in your container builds, use the following\nimage naming pattern in your `Dockerfile`:\n\n```Dockerfile\nFROM ghcr.io/sitepilot/php-{{variation-name}}:{{php-version}}-{{release-version}}\n```\n\nThe images are tagged according to Semantic Versioning (SemVer). Available releases can be found on the [releases page](https://github.com/sitepilot/docker-php/releases). For example, if you wish to customize the **PHP 8.3** with **FPM** \u0026 **NGINX** image:\n\n```Dockerfile\n# Guaranteed backward compatibility, new features and bug fixes.\nFROM ghcr.io/sitepilot/php-nginx:8.3-1\n```\n\n```Dockerfile\n# Guaranteed backward compatibility and bug fixes.\nFROM ghcr.io/sitepilot/php-nginx:8.3-1.0\n```\n\n```Dockerfile\n# Guaranteed backward compatibility and no updates.\nFROM ghcr.io/sitepilot/php-nginx:8.3-1.0.0\n```\n\n## Variations\n\nThe following Docker image variations are available:\n\n| Image                         | Description                            |\n|-------------------------------|----------------------------------------|\n| `ghcr.io/sitepilot/php-cli`   | PHP command line interface.            |\n| `ghcr.io/sitepilot/php-fpm`   | PHP with PHP-FPM.                      |\n| `ghcr.io/sitepilot/php-nginx` | PHP-FPM with Nginx web server.         |\n| `ghcr.io/sitepilot/php-ols`   | PHP-FPM with OpenLitespeed web server. |\n\n## Versions\n\nThe following PHP versions are available:\n\n* PHP 7.4\n* PHP 8.0\n* PHP 8.1\n* PHP 8.2\n* PHP 8.3\n\nYou can find a list of installed PHP extensions for each PHP version [here](./src/packages).\n\n## Environment\n\nThe following environment variables are available to modify the configuration of an image:\n\n| Name                        | Value     | php-nginx | php-ols | php-fpm | php-cli |\n|-----------------------------|-----------|-----------|---------|---------|---------|\n| `PHP_DATE_TIMEZONE`         | `UTC`     | ✅         | ✅       | ✅       | ✅       |\n| `PHP_MEMORY_LIMIT`          | `256M`    | ✅         | ✅       | ✅       | ✅       |\n| `PHP_MAX_EXECUTION_TIME`    | `300`     | ✅         | ✅       | ✅       | ✅       |\n| `PHP_MAX_INPUT_VARS`        | `10000`   | ✅         | ✅       | ✅       | ✅       |\n| `PHP_FPM_CONTROL`           | `dynamic` | ✅         | ✅       | ✅       |         |\n| `PHP_FPM_MAX_CHILDREN`      | `20`      | ✅         | ✅       | ✅       |         |\n| `PHP_FPM_START_SERVERS`     | `2`       | ✅         | ✅       | ✅       |         |\n| `PHP_FPM_MIN_SPARE_SERVERS` | `1`       | ✅         | ✅       | ✅       |         |\n| `PHP_FPM_MAX_SPARE_SERVERS` | `3`       | ✅         | ✅       | ✅       |         |\n| `PHP_POST_MAX_SIZE`         | `100M`    | ✅         | ✅       |         |         |\n| `PHP_UPLOAD_MAX_FILESIZE`   | `100M`    | ✅         | ✅       |         |         |\n\n## Variation Specific Docs\n\n### PHP-NGINX\n\n#### Environment\n\n| Name                         | Value            |\n|------------------------------|------------------|\n| `NGINX_PUBLIC_DIR`           | -                |\n| `NGINX_FASTCGI_PASS`         | `127.0.0.1:9000` |\n\n#### Add a vhost / site\n\nCustom vhosts are loaded from the `/etc/nginx/sites-enabled` folder. Mount a file with a `.conf` extension to this\nfolder to add a custom vhost.\n\n#### Add location directive\n\nCustom location directives are loaded from the `/etc/nginx/location.d` folder. Mount a file with a `.conf` extension to\nthis folder to add a custom location directive.\n\n### PHP-OLS\n\n#### Environment\n\n| Name               | Value            |\n|--------------------|------------------|\n| `OLS_PUBLIC_DIR`   | -                |\n| `OLS_FASTCGI_PASS` | `127.0.0.1:9000` |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsitepilot%2Fdocker-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsitepilot%2Fdocker-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsitepilot%2Fdocker-php/lists"}