sql
gruntwork-io/sql/google
Terraform modules for deploying Google Cloud SQL (e.g. MySQL, PostgreSQL) in GCP
Cloud SQL Modules   !Terraform Version This repo contains modules for running relational databases such as MySQL and PostgreSQL on Google Cloud Platform (GCP) using Cloud SQL. Cloud SQL Architecture !Cloud SQL Architecture Features - Deploy a fully-managed relational database - Supports MySQL and PostgreSQL - Optional failover instances - Optional read replicas Learn This repo is a part of the Gruntwork Infrastructure as Code Library, a collection of reusable, battle-tested, production ready infrastructure code. If you’ve never used the Infrastructure as Code Library before, make sure to read How to use the Gruntwork
| Name | Type | Description | Default |
|---|---|---|---|
| name_prefix | string | The name prefix for the database instance. Will be appended with a random string | required |
| master_user_name | string | The username part for the default user credentials, i.e. 'master_user_name'@'mas | required |
| project | string | The project ID to host the database in. | required |
| region | string | The region to host the database in. | required |
| master_user_password | string | The password part for the default user credentials, i.e. 'master_user_name'@'mas | required |
| db_name | string | Name for the db | "default" |
| postgres_version | string | The engine version of the database, e.g. `POSTGRES_9_6`. See https://cloud.googl | "POSTGRES_9_6" |
| machine_type | string | The machine type to use, see https://cloud.google.com/sql/pricing for more detai | "db-f1-micro" |
| name_override | string | You may optionally override the name_prefix + random string by specifying an ove | "" |
db_name — Name of the default databasedb — Self link to the default databasemaster_instance_name — The name of the database instancemaster_ip_addresses — All IP addresses of the instance as list of maps, see https://www.terraform.io/docs/providers/googlemaster_private_ip — The private IPv4 address of the master instancemaster_instance — Self link to the master instancemaster_proxy_connection — Instance path for connecting with Cloud SQL Proxy. Read more at https://cloud.google.com/sql/docs/my