![]() ![]() ![]() ![]() XDEBUG_CONFIG: "remote_host=" #This config works for MacOS, otherwise should be ip address of the host machine because docker container cannot find the host by localhost. configs/db/:/docker-entrypoint-initdb.d # mysql will execute the initial sql script under the mount point one by one It connects with the database, edit tables and schemas, run queries, and even analyze schema with UML diagram. How to initialize MySQL container with sql script file.ĭocker-compose.yml for container managementĬommand: -max_allowed_packet=1073741824 -sql_mode="STRICT_TRANS_TABLES,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION" PhpStorm provides tools and code assistance features for working with databases and SQL in your projects.Integrate Xdebug plugin with docker container as well as PHPStorm.Export production db to dev Mysql docker container.Use Docker compose to mange docker containers.Then, what we need to do is to setup a development environment for that site so that we can customize plugins or what else. In this article, I’m going to introduce a more convenient way to quickly set up development environment with PHPStorm, Docker, Docker compose and Xdebug. The source code for docker compose configs are available in the Github: įirst of all, suppose we have installed Docker and Docker compose in a Linux-like OS, and installed a Wordpress site in production. Xdebug is an extension for PHP to assist with debugging and development. It’s a common practice to debug PHP using Xdebug. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |