|
| 1 | +# Gemini CLI Extension - Cloud SQL for SQL Server |
| 2 | + |
| 3 | +This Gemini CLI extension provides a set of tools to interact with [Cloud SQL for SQL Server](https://cloud.google.com/sql/docs/sqlserver) instances. It allows you to manage your databases, execute queries, and explore schemas directly from the [Gemini CLI](https://google-gemini.github.io/gemini-cli/), using natural language prompts. |
| 4 | + |
| 5 | +## Features |
| 6 | + |
| 7 | +* **Integrated with Gemini CLI:** As a Google-developed extension, it integrates seamlessly into the Gemini CLI environment, making security an accessible part of your workflow. |
| 8 | +* **Connect to Cloud SQL for SQL Server:** Securely connect to your Cloud SQL for SQL Server instances. |
| 9 | +* **Explore Database Schema:** List databases, tables, views, and schemas. |
| 10 | +* **Query your Database:** Execute SQL queries against your database. |
| 11 | + |
| 12 | +## Supported Tools |
| 13 | + |
| 14 | +* `list_tables` |
| 15 | +* `execute_sql` |
| 16 | + |
| 17 | +## Prerequisites |
| 18 | + |
| 19 | +Before you begin, ensure you have the following: |
| 20 | + |
| 21 | +* [Gemini CLI](https://github.com/google-gemini/gemini-cli) installed. |
| 22 | +* A Google Cloud project with the **Cloud SQL Admin API** enabled. |
| 23 | +* IAM Permissions |
| 24 | + |
| 25 | +## Installation |
| 26 | + |
| 27 | +To install the extension, use the `gemini extensions install` command: |
| 28 | + |
| 29 | +```bash |
| 30 | +gemini extensions install github.com/gemini-cli-extensions/cloud-sql-sqlserver.git |
| 31 | +``` |
| 32 | + |
| 33 | +## Configuration |
| 34 | + |
| 35 | +* `CLOUD_SQL_MSSQL_PROJECT`: The GCP project ID. |
| 36 | +* `CLOUD_SQL_MSSQL_REGION`: The region of your Cloud SQL instance. |
| 37 | +* `CLOUD_SQL_MSSQL_INSTANCE`: The ID of your Cloud SQL instance. |
| 38 | +* `CLOUD_SQL_MSSQL_DATABASE`: The name of the database to connect to. |
| 39 | +* `CLOUD_SQL_MSSQL_IP_ADDRESS`: The IP address of the Cloud SQL instance. |
| 40 | +* `CLOUD_SQL_MSSQL_USER`: The database username. |
| 41 | +* `CLOUD_SQL_MSSQL_PASSWORD`: The password for the database user. |
| 42 | + |
| 43 | +## Usage |
| 44 | + |
| 45 | +* Provision Infrastructure |
| 46 | +* Explore Schemas and Data |
| 47 | +* Generate code |
| 48 | + |
| 49 | +## Security |
| 50 | + |
| 51 | +This extension executes commands against your Cloud SQL for SQL Server database. Always review the generated SQL queries before execution, especially for write operations. |
| 52 | + |
| 53 | +## Disclaimer |
| 54 | + |
| 55 | +This is not an officially supported Google product. This extension is under active development, and breaking changes may be introduced. |
0 commit comments