{"id":20364920,"url":"https://github.com/joeri-abbo/wpdc-wordpress-docker-compose","last_synced_at":"2026-05-07T02:36:10.614Z","repository":{"id":103511223,"uuid":"510495644","full_name":"Joeri-Abbo/WPDC-wordpress-docker-compose","owner":"Joeri-Abbo","description":"Stack for local development of a WordPress project","archived":false,"fork":false,"pushed_at":"2022-07-04T20:36:13.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-15T04:30:10.416Z","etag":null,"topics":["development","docker","docker-compose","stack","wordpress"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/Joeri-Abbo.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,"publiccode":null,"codemeta":null}},"created_at":"2022-07-04T20:32:06.000Z","updated_at":"2022-07-06T17:46:32.000Z","dependencies_parsed_at":"2023-03-13T15:08:06.602Z","dependency_job_id":null,"html_url":"https://github.com/Joeri-Abbo/WPDC-wordpress-docker-compose","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joeri-Abbo%2FWPDC-wordpress-docker-compose","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joeri-Abbo%2FWPDC-wordpress-docker-compose/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joeri-Abbo%2FWPDC-wordpress-docker-compose/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Joeri-Abbo%2FWPDC-wordpress-docker-compose/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Joeri-Abbo","download_url":"https://codeload.github.com/Joeri-Abbo/WPDC-wordpress-docker-compose/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241904711,"owners_count":20040021,"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":["development","docker","docker-compose","stack","wordpress"],"created_at":"2024-11-15T00:14:15.984Z","updated_at":"2026-05-07T02:36:05.577Z","avatar_url":"https://github.com/Joeri-Abbo.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WPDC - WordPress Docker Compose\n\nEasy WordPress development with Docker and Docker Compose.\n\nWith this project you can quickly run the following:\nContents:\n\n- [Requirements](#requirements)\n- [Configuration](#configuration)\n- [Installation](#installation)\n- [Usage](#usage)\n\n## Requirements\n\nMake sure you have the latest versions of **Docker** and **Docker Compose** installed on your machine.\n\n## Configuration\n\nCopy the example environment into `.env`\n\n```\ncp env.example .env\n```\n\nEdit the `.env` file to change the default IP address, MySQL root password and WordPress database name.\n\n## Installation\n\nOpen a terminal and `cd` to the folder in which `docker-compose.yml` is saved and run:\n\n```\ndocker-compose up\n```\n\nThis creates two new folders next to your `docker-compose.yml` file.\n\n* `wp-data` – used to store and restore database dumps\n* `wp-app` – the location of your WordPress application\n\nThe containers are now built and running. You should be able to access the WordPress installation with the configured IP\nin the browser address. By default it is `http://127.0.0.1`.\n\nFor convenience you may add a new entry into your hosts file.\n\n## Usage\n\n### Starting containers\n\nYou can start the containers with the `up` command in daemon mode (by adding `-d` as an argument) or by using\nthe `start` command:\n\n```\ndocker-compose start\n```\n\n### Stopping containers\n\n```\ndocker-compose stop\n```\n\n### Removing containers\n\nTo stop and remove all the containers use the`down` command:\n\n```\ndocker-compose down\n```\n\nUse `-v` if you need to remove the database volume which is used to persist the database:\n\n```\ndocker-compose down -v\n```\n\n### Project from existing source\n\nCopy the `docker-compose.yml` file into a new directory. In the directory you create two folders:\n\n* `wp-data` – here you add the database dump\n* `wp-app` – here you copy your existing WordPress code\n\nYou can now use the `up` command:\n\n```\ndocker-compose up\n```\n\nThis will create the containers and populate the database with the given dump. You may set your host entry and change it\nin the database, or you simply overwrite it in `wp-config.php` by adding:\n\n```\ndefine('WP_HOME','http://example.com');\ndefine('WP_SITEURL','http://example.com');\n```\n\n### Creating database dumps\n\n```\n./export.sh\n```\n\n### Developing a Theme\n\nConfigure the volume to load the theme in the container in the `docker-compose.yml`:\n\n```\nvolumes:\n  - ./theme-name/trunk/:/var/www/html/wp-content/themes/theme-name\n```\n\n### Developing a Plugin\n\nConfigure the volume to load the plugin in the container in the `docker-compose.yml`:\n\n```\nvolumes:\n  - ./plugin-name/trunk/:/var/www/html/wp-content/plugins/plugin-name\n```\n\n### WP CLI\n\nThe docker compose configuration also provides a service for using\nthe [WordPress CLI](https://developer.wordpress.org/cli/commands/).\n\nSample command to install WordPress:\n\n```\ndocker-compose run --rm wpcli wp core install --url=http://localhost --title=test --admin_user=admin --admin_email=test@example.com\n```\n\nOr to list installed plugins:\n\n```\ndocker-compose run --rm wpcli wp plugin list\n```\n\nFor an easier usage you may consider adding an alias for the CLI:\n\n```\nalias wp=\"docker-compose run --rm wpcli\"\n```\n\nThis way you can use the CLI command above as follows:\n\n```\nwp plugin list\n```\n\n### phpMyAdmin\n\nYou can also visit `http://127.0.0.1:8080` to access phpMyAdmin after starting the containers.\n\nThe default username is `root`, and the password is the same as supplied in the `.env` file.\n\n### nginx\n\nYou can enable the nginx reverse proxy to serve the WordPress application.\nTo do this you need to uncomment the `nginx` section in the `docker-compose.yml` file.\nDo not forget to change the ip in the wp service\n\nThen you can start the containers with the `up` command:\n\n```\ndocker-compose build --no-cache \u0026\u0026 docker-compose up\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoeri-abbo%2Fwpdc-wordpress-docker-compose","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoeri-abbo%2Fwpdc-wordpress-docker-compose","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoeri-abbo%2Fwpdc-wordpress-docker-compose/lists"}