Home > Software design >  Is it possible to have a docker compose yaml file for WordPress and have google cloudsql as its data
Is it possible to have a docker compose yaml file for WordPress and have google cloudsql as its data

Time:10-12

I want to use google cloud run for my WordPress site and have google cloud sql as its db. So far, I was able to achieve this using a Dockerfile. The media files are offloaded to google cloud storage so they are persistent but the plugin updates are still ephemeral. I found some articles saying I need to mount a volume for the plugins to be persistent but all of the tutorials/articles for this uses mysql or any other db container for the WordPress instance to connect on in the docker compose yaml file.

I need a docker compose file that only starts up WordPress, then lets it connect to my google cloud sql.

I don't know how to proceed now.

CodePudding user response:

Yes, it is possible to use Google Cloud SQL with Docker Compose. You can find a sample docker-compose.yml file in the Google Cloud SQL documentation.

  • Related