{"id":21262984,"url":"https://github.com/michaelbunch/contain-my-php","last_synced_at":"2026-05-01T18:32:25.959Z","repository":{"id":210312669,"uuid":"84869174","full_name":"michaelbunch/contain-my-php","owner":"michaelbunch","description":"Docker container orchestration for local PHP development.","archived":false,"fork":false,"pushed_at":"2017-07-10T13:46:16.000Z","size":4,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-08-06T15:45:05.593Z","etag":null,"topics":["blackfire","docker","mysql","nginx","php","php-fpm","xdebug"],"latest_commit_sha":null,"homepage":"","language":"Nginx","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/michaelbunch.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-03-13T20:02:05.000Z","updated_at":"2017-07-10T13:49:35.000Z","dependencies_parsed_at":"2023-12-01T23:44:00.370Z","dependency_job_id":null,"html_url":"https://github.com/michaelbunch/contain-my-php","commit_stats":null,"previous_names":["michaelbunch/contain-my-php"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/michaelbunch/contain-my-php","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michaelbunch%2Fcontain-my-php","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michaelbunch%2Fcontain-my-php/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michaelbunch%2Fcontain-my-php/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michaelbunch%2Fcontain-my-php/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/michaelbunch","download_url":"https://codeload.github.com/michaelbunch/contain-my-php/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/michaelbunch%2Fcontain-my-php/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32508901,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["blackfire","docker","mysql","nginx","php","php-fpm","xdebug"],"created_at":"2024-11-21T04:59:54.503Z","updated_at":"2026-05-01T18:32:25.941Z","avatar_url":"https://github.com/michaelbunch.png","language":"Nginx","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PHP Docker Containers\n\n## Overview\n\nThis is a pretty straight forward project for running a PHP development environment in Docker.\n\n## Requirements\n\nThe only requirements for running this project are Docker Engine and Docker Compose. You can find instructions\nfor installing these at:\n\n- Docker Engine [https://docs.docker.com/engine/installation/]()\n- Docker Compose [https://docs.docker.com/compose/install/]()\n\nNOTE: The remainder of this document will assume you already have these installed and configured.\n\n## Up and Running\n\nTo get up and running fast, just drop the `containers` folder and `docker-compose.yml` file into the root\nof your project. Then, from the command line, run `docker-compose up -d`.\n\n## What Happened and How Do I Use It?\n\nAfter running `docker-compose`, containers for nginx, php-fpm, blackfire.io, and MySQL will build and start.\nNginx will be accessible from `http://localhost`, but default ports on the other containers are only \nexposed within the Docker network.**\n\nNginx is configured to send PHP requests to the PHP-FPM container. PHP-FPM has access to the MySQL \ncontainer for queries and the host machine for sending Xdebug output. Blackfire.io profiling can be initiated \nby running the Blackfire Companion in Chrome*** while viewing the site.\n\n** Docker exposes alternate, random ports for each of these containers to be accessed from the host machine. \nRun `docker ps` to see which ports.\n\n*** This is my prefered method and not a requirement.\n\n## Containers\n\n### Nginx\n\nThe official Docker Nginx container. It has only been customized to send PHP requests to the PHP-FPM\ncontainer on port `9000`.\n\nVersion: 1.11.x\n\n### PHP-FPM\n\nThe official Docker PHP container. This has PHP-FPM installed with extensions for MBString, Mcrypt, PDO-MySQL,\nXdebug, and Blackfire.io Agent. In order for Xdebug to send information to your development machine, you'll need\ninclude the actual network IP address (not the internat Docker IP) of the host machine in the environment\nvariable `XDEBUG_HOST`. See this [https://shippingdocker.com/xdebug/auto-config/](screencast) for more details \non how it works.\n\nVersion: 7.1.x\n\n### Blackfire.io Agent\n\nThe official Blackfire.io Docker image. No modifications have been made to this container. Environment variables \nshould be setup for `BLACKFIRE_SERVER_ID` and `BLACKFIRE_SERVER_TOKEN` on the host machine. \n\nVersion: latest\n\n### MySQL\n\nThe official MySQL Docker image. No modifications have been made to this container. Environment variables \nare already configured to run the image, but you may wish to make changes.\n\nVersion: 5.7.x\n\n### Redis Server\n\nThe official Redis Docker image. No modifications have been made to this container. Environment variables \nare already configured to run the image, but you may wish to make changes.\n\n### Selenium Standalone Chrome\n\nThe official Selenium Docker image. No modifications have been made to this container. Environment variables \nare already configured to run the image, but you may wish to make changes.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichaelbunch%2Fcontain-my-php","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmichaelbunch%2Fcontain-my-php","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmichaelbunch%2Fcontain-my-php/lists"}