SQL Admin
Compute Engine
Service Networking
VPC Networks
and select Create VPC Network
.Create
.
SQL
and select Create Instance
.Show Configuration Options
to drop down more options.Connections
tab, disable Public IP and enable Private IP.Set up connection
.Continue
and Create Connection
gcloud
CLI to edit the Cloud SQL instance. When patching the Cloud SQL instance, you must specify the allowed consumer project id(s) that will be used to consume the instance.gcloud
command:---enable-private-service-connect
flag.Connections
in your instance.Owner
(if you are the owner of the project)Service Usage Admin
, Cloudsql Admin
, and Compute Network Admin
(minimum permissions required)ipv4_enabled
is set to false
. This ensures that Cloud SQL uses a private IP and is not assigned a public IP.psc_config
is set up with psc_enabled
as true
producer_vpc_self_link
will be inserted after the infrastructure.tf
file is applied.terraform.tfvars
vpc_self_link
output and copy/paste that value to your terraform.tfvars