Skip to content

Latest commit

 

History

History
14 lines (13 loc) · 560 Bytes

README.md

File metadata and controls

14 lines (13 loc) · 560 Bytes

cloud-run-wordpress

Medium article: Deploy a Wordpress site on Google Cloud Run

Deploy steps

Build image

gcloud builds submit --tag gcr.io/[PROJECT-ID]/wp:v1

Deploy image

gcloud beta run deploy wp --image gcr.io/[PROJECT-ID]/wp:v1 \
--add-cloudsql-instances <instance-name> \
--update-env-vars DB_HOST='127.0.0.1',DB_NAME=<dbname>,DB_USER=<dbuser>,DB_PASSWORD=<dbpass>,CLOUDSQL_INSTANCE='<project.id>:<region>:<instance-name>'