
MCP服务器用于将应用部署到Cloud Run
概览
启用兼容MCP的AI代理,将应用部署到Cloud Run。 从Gemini CLI及其他AI驱动的CLI代理部署: 从代理SDK部署,比如Google Gen AI SDK或代理开发工具包。 这是一个MCP服务器的仓库,用于将代码部署到Cloud Run,想了解如何在Cloud Run上运行MCP服务器,请访问Cloud Run文档。 - deploy-file-contents:通过直接提供文件内容,将文件部署到Cloud Run。- list-services:列出特定项目和区域的Cloud Run服务。- get-service:获取特定Cloud Run服务的详细信息。- get-service-log:获取特定Cloud Run服务的日志和错误消息。 - deploy-local-folder\:将本地文件夹部署到 Google Cloud Run 服务。- list-projects\:列出可用的 GCP 项目。- create-project*:创建一个新的 GCP 项目并将其附加到第一个可用的计费账户。可选地指定项目 ID。 提示词是可用于执行常见任务的自然语言命令。
概述(AI 翻译)
启用兼容MCP的AI代理,将应用部署到Cloud Run。
从Gemini CLI及其他AI驱动的CLI代理部署:
从AI驱动的IDE部署:
从AI助手应用部署:
从代理SDK部署,比如Google Gen AI SDK或代理开发工具包。
[!注] 这是一个MCP服务器的仓库,用于将代码部署到Cloud Run,想了解如何托管 MCP服务器到Cloud Run,请访问Cloud Run文档。
工具
-
deploy-file-contents:通过直接提供文件内容部署到 Cloud Run。 -
list-services:列出给定项目和地区的云运行服务。 -
get-service:获取特定云运行服务的详细信息。 -
get-service-log:获取特定云运行服务的日志和错误消息。 -
deploy-local-folder*:将本地文件夹部署到Google Cloud Run服务。 -
list-projects*:列出可用的GCP项目。 -
create-project*:创建一个新的GCP项目并将其附加到第一个可用的计费账户。可选地指定项目ID。
_* 仅在运行locally_时使用。
提示
提示词是可用于执行常见任务的自然语言命令。
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
Cloud Run MCP server and Gemini CLI extension
Enable MCP-compatible AI agents to deploy apps to Cloud Run.
"mcpServers":{
"cloud-run": {
"command": "npx",
"args": ["-y", "@google-cloud/cloud-run-mcp"]
}
}
Deploy from Gemini CLI and other AI-powered CLI agents:
Deploy from AI-powered IDEs:
Deploy from AI assistant apps:
Deploy from agent SDKs, like the Google Gen AI SDK or Agent Development Kit.
[!NOTE]
This is the repository of an MCP server to deploy code to Cloud Run, to learn how to host MCP servers on Cloud Run, visit the Cloud Run documentation.
Tools
-
deploy-file-contents: Deploys files to Cloud Run by providing their contents directly. -
list-services: Lists Cloud Run services in a given project and region. -
get-service: Gets details for a specific Cloud Run service. -
get-service-log: Gets Logs and Error Messages for a specific Cloud Run service. -
deploy-local-folder*: Deploys a local folder to a Google Cloud Run service. -
list-projects*: Lists available GCP projects. -
create-project*: Creates a new GCP project and attach it to the first available billing account. A project ID can be optionally specified.
* only available when running locally
Prompts
Prompts are natural language commands that can be used to perform common tasks. They are shortcuts for executing tool calls with pre-filled arguments.
deploy: Deploys the current working directory to Cloud Run. If a service name is not provided, it will use theDEFAULT_SERVICE_NAMEenvironment variable, or the name of the current working directory.logs: Gets the logs for a Cloud Run service. If a service name is not provided, it will use theDEFAULT_SERVICE_NAMEenvironment variable, or the name of the current working directory.
Environment Variables
The Cloud Run MCP server can be configured using the following environment variables:
| Variable | Description |
|---|
安装
npx -y @google-cloud/cloud-run-mcp配置
"mcpServers":{
"cloud-run": {
"command": "npx",
"args": ["-y", "@google-cloud/cloud-run-mcp"]
}
}