Mysql docker image



I wonder if any of you have tried mysql docker image or any other type of simple database system (firebird or H2, easy to figure and reliable and supported by lucee) and have lucee docker image to connect to it and create a lucee datasource for its db data manipulation. A quick googling suggests mysql docker image is available, however, I couldn’t find any resource on its relation to lucee docker image.



…and now you’re going to want to learn docker-compose.

You’ll find MySQL or MariaDB images on docker hub. Each one will define how to configure it.

Consider this example, which is pretty much exactly what you want. Swap lucee for wordpress.

Set reasonable values for your environment

Then configure your datasource in Application.cfc, or lucee administrator (using db as the hostname - docker will resolve db to the IP address of the db service in your compose file.)

You’ll also want to be sure you keep that volume around or you’ll lose your data. (or do a volume mount instead)





I appreciate your insight. For now, I’ll skip MySQL docker image because the file creation/write/append is now working.