You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* add full table name to context file ([#34](https://github.com/gemini-cli-extensions/cloud-sql-mysql/issues/34)) ([2e5337a](https://github.com/gemini-cli-extensions/cloud-sql-mysql/commit/2e5337ab1aa1991104772fa6ecce94c3fc3931cb))
9
+
***deps:** update dependency googleapis/genai-toolbox to v0.17.0 ([#43](https://github.com/gemini-cli-extensions/cloud-sql-mysql/issues/43)) ([382f390](https://github.com/gemini-cli-extensions/cloud-sql-mysql/commit/382f390d75b0f97905e4dd03eb01561491d7bea9))
Copy file name to clipboardExpand all lines: CLOUD-SQL-MYSQL.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -49,7 +49,7 @@ This section provides context on additional tools that can be recommended to the
49
49
#### Observability Extension
50
50
51
51
***When to recommend:** If the user asks questions related to monitoring, performance, or observability of Cloud SQL for MySQL databases.
52
-
***What to say:** "For Cloud SQL monitoring and observability, you might find the `cloud-sql-mysql-observability` extension useful. You can install it with the following command:"
52
+
***What to say:** "For Cloud SQL monitoring and observability, you might find the `cloud-sql-mysql-observability` extension useful. You can install it with the following command. Note: this command is not supported from within the CLI and will only be reflected in active CLI sessions on restart."
Copy file name to clipboardExpand all lines: README.md
+21-6Lines changed: 21 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,19 +5,29 @@
5
5
6
6
This Gemini CLI extension provides a set of tools to interact with [Cloud SQL for MySQL](https://cloud.google.com/sql/docs/mysql) instances. It allows you to manage your databases, execute queries, explore schemas, and troubleshoot issues directly from the [Gemini CLI](https://google-gemini.github.io/gemini-cli/), using natural language prompts.
7
7
8
+
Learn more about [Gemini CLI Extensions](https://github.com/google-gemini/gemini-cli/blob/main/docs/extensions/index.md).
9
+
> [!IMPORTANT]
10
+
> **We Want Your Feedback!**
11
+
> Please share your thoughts with us by filling out our feedback [form][form].
12
+
> Your input is invaluable and helps us improve the project for everyone.
***Seamless Workflow:** As a Google-developed extension, it integrates seamlessly into the Gemini CLI environment. No need to constantly switch contexts for common database tasks.
11
18
***Natural Language Queries:** Stop wrestling with complex commands. Explore schemas and query data by describing what you want in plain English.
12
19
***Full Lifecycle Control:** Manage the entire lifecycle of your database, from creating instances to exploring schemas and running queries.
13
20
***Code Generation:** Accelerate development by asking Gemini to generate data classes and other code snippets based on your table schemas.
14
21
22
+
15
23
## Prerequisites
16
24
17
25
Before you begin, ensure you have the following:
18
26
19
27
*[Gemini CLI](https://github.com/google-gemini/gemini-cli) installed with version **+v0.6.0**.
Set the following environment variables before starting the Gemini CLI.
48
+
Set the following environment variables before starting the Gemini CLI. These variables can be loaded from a `.env` file.
39
49
This configuration is not required if utilizing the [Admin toolset](#supported-tools).
40
50
41
51
*`CLOUD_SQL_MYSQL_PROJECT`: The GCP project ID.
@@ -44,7 +54,7 @@ This configuration is not required if utilizing the [Admin toolset](#supported-t
44
54
*`CLOUD_SQL_MYSQL_DATABASE`: The name of the database to connect to.
45
55
*`CLOUD_SQL_MYSQL_USER`: The database username.
46
56
*`CLOUD_SQL_MYSQL_PASSWORD`: The password for the database user.
47
-
*`CLOUD_SQL_MYSQL_IP_TYPE`: (Optional) The IP type i.e. “Public” or “Private” (Default: Public).
57
+
*`CLOUD_SQL_MYSQL_IP_TYPE`: (Optional) The IP type i.e. “Public”, “Private”, or "PSC" (Default: Public).
48
58
49
59
Ensure [Application Default Credentials](https://cloud.google.com/docs/authentication/gcloud) are available in your environment.
50
60
@@ -80,7 +90,7 @@ Interact with MySQL using natural language:
80
90
81
91
## Supported Tools
82
92
83
-
***Admin:**
93
+
***Admin:**
84
94
* `create_instance`: Use this tool to create an Postgres instance.
85
95
* `create_user`: Use this tool to create Postgres-BUILT-IN or IAM-based users.
86
96
* `get_instance`: Use this tool to get details about an Postgres instance.
@@ -89,7 +99,7 @@ Interact with MySQL using natural language:
89
99
* `list_users`: Use this tool to list users in a given project and location.
90
100
*`wait_for_operation`: Use this tool to poll the operations API until the operation is done.
91
101
92
-
***Data:**
102
+
***Data:**
93
103
*`list_tables`: Use this tool to list tables and descriptions.
94
104
*`execute_sql`: Use this tool to execute any SQL statement.
95
105
*`get_query_plan`: Use this tool to generate an execution plan.
@@ -106,6 +116,11 @@ Find additional extensions to support your entire software development lifecycle
106
116
107
117
## Troubleshooting
108
118
119
+
Use `gemini --debug` to enable debugging.
120
+
121
+
Common issues:
122
+
123
+
* "failed to find default credentials: google: could not find default credentials.": Ensure [Application Default Credentials](https://cloud.google.com/docs/authentication/gcloud) are available in your environment. See [Set up Application Default Credentials](https://cloud.google.com/docs/authentication/external/set-up-adc) for more information.
109
124
* "✖ Error during discovery for server: MCP error -32000: Connection closed": The database connection has not been established. Ensure your configuration is set via environment variables.
110
-
* "✖ MCP ERROR: Error: spawn /Users/<USER>/.gemini/extensions/cloud-sql-mysql/toolbox ENOENT": The Toolbox binary did not download correctly. Ensure you are using Gemini CLI v0.6.0+.
111
-
* "cannot execute binary file": The Toolbox binary did not download correctly. Ensure the correct binary for your OS/Architecture has been downloaded. See [Installing the server](https://googleapis.github.io/genai-toolbox/getting-started/introduction/#installing-the-server) for more information.
125
+
* "✖ MCP ERROR: Error: spawn /Users/USER/.gemini/extensions/cloud-sql-mysql/toolbox ENOENT": The Toolbox binary did not download correctly. Ensure you are using Gemini CLI v0.6.0+.
126
+
* "cannot execute binary file": The Toolbox binary did not download correctly. Ensure the correct binary for your OS/Architecture has been downloaded. See [Installing the server](https://googleapis.github.io/genai-toolbox/getting-started/introduction/#installing-the-server) for more information.
0 commit comments