Part I:
Setting Up Lumen and MySQL With Docker - Part I
Part II:
Setting Up Lumen and MySQL With Docker - Part II
-
Rename
.env.example
to.env
(or use your own.env
) -
In
.env
, changeDB_HOST=127.0.0.1
toDB_HOST=your_mysql_container_name
(DB_HOST=db
in this example) -
Build and run project with:
docker-compose --env-file .env up --build