A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/GoogleCloudPlatform/cloud-run-mcp below:

GoogleCloudPlatform/cloud-run-mcp: MCP server to deploy apps to Cloud Run

MCP server to deploy code to Google Cloud Run

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 AI-powered IDEs:

Deploy from AI assistant apps:

Deploy from agent SDKs, like the Google Gen AI SDK or Agent Development Kit.

* only available when running locally

Prompts are natural language commands that can be used to perform common tasks. They are shortcuts for executing tool calls with pre-filled arguments.

Run the Cloud Run MCP server on your local machine using local Google Cloud credentials. This is best if you are using an AI-assisted IDE (e.g. Cursor) or a desktop AI application (e.g. Claude).

  1. Install the Google Cloud SDK and authenticate with your Google account.

  2. Log in to your Google Cloud account using the command:

  3. Set up application credentials using the command:

    gcloud auth application-default login

Then configure the MCP server using either Node.js or Docker:

  1. Install Node.js (LTS version recommended).

  2. Update the MCP configuration file of your MCP client with the following:

       "cloud-run": {
         "command": "npx",
         "args": ["-y", "@google-cloud/cloud-run-mcp"]
       }
  3. [Optional] Add default configurations

       "cloud-run": {
          "command": "npx",
          "args": ["-y", "@google-cloud/cloud-run-mcp"],
          "env": {
                "GOOGLE_CLOUD_PROJECT": "PROJECT_NAME",
                "GOOGLE_CLOUD_REGION": "PROJECT_REGION",
                "DEFAULT_SERVICE_NAME": "SERVICE_NAME"
          }
       }

See Docker's MCP catalog, or use these manual instructions:

  1. Install Docker

  2. Update the MCP configuration file of your MCP client with the following:

       "cloud-run": {
         "command": "docker",
         "args": [
           "run",
           "-i",
           "--rm",
           "-e",
           "GOOGLE_APPLICATION_CREDENTIALS",
           "-v",
           "/local-directory:/local-directory",
           "mcp/cloud-run-mcp:latest"
         ],
         "env": {
           "GOOGLE_APPLICATION_CREDENTIALS": "/Users/slim/.config/gcloud/application_default-credentials.json",
           "DEFAULT_SERVICE_NAME": "SERVICE_NAME"
         }
       }
Use as a Gemini CLI extension

To install this as a Gemini CLI extension, run the following command:

mkdir -p ~/.gemini/extensions/cloud-run/gemini-extension && \
  curl -s -L https://raw.githubusercontent.com/GoogleCloudPlatform/cloud-run-mcp/main/gemini-extension.json > ~/.gemini/extensions/cloud-run/gemini-extension.json && \
  curl -s -L https://raw.githubusercontent.com/GoogleCloudPlatform/cloud-run-mcp/main/gemini-extension/GEMINI.md > ~/.gemini/extensions/cloud-run/gemini-extension/GEMINI.md

Warning

Do not use the remote MCP server without authentication. In the following instructions, we will use IAM authentication to secure the connection to the MCP server from your local machine. This is important to prevent unauthorized access to your Google Cloud resources.

Run the Cloud Run MCP server itself on Cloud Run with connection from your local machine authenticated via IAM. With this option, you will only be able to deploy code to the same Google Cloud project as where the MCP server is running.

  1. Install the Google Cloud SDK and authenticate with your Google account.

  2. Log in to your Google Cloud account using the command:

  3. Set your Google Cloud project ID using the command:

    gcloud config set project YOUR_PROJECT_ID
  4. Deploy the Cloud Run MCP server to Cloud Run:

    gcloud run deploy cloud-run-mcp --image us-docker.pkg.dev/cloudrun/container/mcp --no-allow-unauthenticated

    When prompted, pick a region, for example europe-west1.

    Note that the MCP server is not publicly accessible, it requires authentication via IAM.

  5. [Optional] Add default configurations

    gcloud run services update cloud-run-mcp --region=REGION --update-env-vars GOOGLE_CLOUD_PROJECT=PROJECT_NAME,GOOGLE_CLOUD_REGION=PROJECT_REGION,DEFAULT_SERVICE_NAME=SERVICE_NAME,SKIP_IAM_CHECK=false
  6. Run a Cloud Run proxy on your local machine to connect securely using your identity to the remote MCP server running on Cloud Run:

    gcloud run services proxy cloud-run-mcp --port=3000 --region=REGION --project=PROJECT_ID

    This will create a local proxy on port 3000 that forwards requests to the remote MCP server and injects your identity.

  7. Update the MCP configuration file of your MCP client with the following:

       "cloud-run": {
         "url": "http://localhost:3000/sse"
       }
    

    If your MCP client does not support the url attribute, you can use mcp-remote:

       "cloud-run": {
         "command": "npx",
         "args": ["-y", "mcp-remote", "http://localhost:3000/sse"]
       }

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4