1
0
mirror of synced 2025-12-19 18:05:44 -05:00

Rename mysql to cloud-sql

This commit is contained in:
Petri Autero
2019-02-14 22:29:33 +02:00
parent 5d6561bada
commit 53c2e6b204
16 changed files with 42 additions and 42 deletions

View File

@@ -64,11 +64,11 @@ resource "google_service_networking_connection" "private_vpc_connection" {
# CREATE DATABASE INSTANCE WITH PRIVATE IP
# ------------------------------------------------------------------------------
module "mysql" {
module "postgres" {
# When using these modules in your own templates, you will need to use a Git URL with a ref attribute that pins you
# to a specific version of the modules, such as the following example:
# source = "git::git@github.com:gruntwork-io/terraform-google-sql.git//modules/mysql?ref=v0.1.0"
source = "../../modules/mysql"
# source = "git::git@github.com:gruntwork-io/terraform-google-sql.git//modules/cloud-sql?ref=v0.1.0"
source = "../../modules/cloud-sql"
project = "${var.project}"
region = "${var.region}"

View File

@@ -1,34 +1,34 @@
output "master_instance_name" {
description = "The name of the database instance"
value = "${module.mysql.master_instance_name}"
value = "${module.postgres.master_instance_name}"
}
output "master_ip_addresses" {
description = "All IP addresses of the instance as list of maps, see https://www.terraform.io/docs/providers/google/r/sql_database_instance.html#ip_address-0-ip_address"
value = "${module.mysql.master_ip_addresses}"
value = "${module.postgres.master_ip_addresses}"
}
output "master_private_ip" {
description = "The first IPv4 address of the addresses assigned to the instance. As this instance has only private IP, it is the private IP address."
value = "${module.mysql.master_first_ip_address}"
value = "${module.postgres.master_first_ip_address}"
}
output "master_instance" {
description = "Self link to the master instance"
value = "${module.mysql.master_instance}"
value = "${module.postgres.master_instance}"
}
output "master_proxy_connection" {
description = "Instance path for connecting with Cloud SQL Proxy. Read more at https://cloud.google.com/sql/docs/mysql/sql-proxy"
value = "${module.mysql.master_proxy_connection}"
value = "${module.postgres.master_proxy_connection}"
}
output "db_name" {
description = "Name of the default database"
value = "${module.mysql.db_name}"
value = "${module.postgres.db_name}"
}
output "db" {
description = "Self link to the default database"
value = "${module.mysql.db}"
value = "${module.postgres.db}"
}