- INFORMATION
-
gcloud beta sql connectis not available in universe domainuniverse. - NAME
-
- gcloud beta sql connect - connects to a Cloud SQL instance
- SYNOPSIS
-
-
gcloud beta sql connectINSTANCE[--database=DATABASE,-dDATABASE] [--debug-logs] [--port=PORT; default=9470] [--run-connection-test] [--skip-ssl] [--auto-iam-authn|--user=USER,-uUSER] [--auto-ip|--private-ip|--psc] [GCLOUD_WIDE_FLAG …]
-
- DESCRIPTION
-
(BETA)Connects to a Cloud SQL instance. - EXAMPLES
-
To connect to a Cloud SQL instance, run:
gcloud beta sql connect my-instance --user=root - POSITIONAL ARGUMENTS
-
INSTANCE- Cloud SQL instance ID.
- FLAGS
-
--database=DATABASE,-dDATABASE- The PostgreSQL or SQL Server database to connect to.
--debug-logs- Enable verbose debug logs for Cloud SQL Proxy.
--port=PORT; default=9470- Port number that gcloud will use to connect to the Cloud SQL Proxy through localhost.
--run-connection-test- Run connection test for Cloud SQL Proxy.
--skip-ssl- Skip SSL certificate verification for MySQL instances.
-
User selection settings for Cloud SQL Proxy connection.
At most one of these can be specified:
--auto-iam-authn- Enables IAM database authentication for connections to MySQL and Postgres instances.
--user=USER,-uUSER- Cloud SQL instance user to connect as.
-
IP address selection settings for Cloud SQL Proxy connection.
At most one of these can be specified:
--auto-ip- Connect to the Cloud SQL instance with auto IP detection.
--private-ip- Connect to the Cloud SQL instance using private IP.
--psc- Connect to the Cloud SQL instance using Private Service Connect.
- GCLOUD WIDE FLAGS
-
These flags are available to all commands:
--access-token-file,--account,--billing-project,--configuration,--flags-file,--flatten,--format,--help,--impersonate-service-account,--log-http,--project,--quiet,--trace-token,--user-output-enabled,--verbosity.Run
$ gcloud helpfor details. - NOTES
-
This command is currently in beta and might change without notice. These
variants are also available:
gcloud sql connectgcloud alpha sql connect
gcloud beta sql connect
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-11-04 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-11-04 UTC."],[],[]]