← ClaudeAtlas

gcloud-authlisted

Container-adapted Google Cloud CLI authentication. Supports service account key files, application default credentials, and browser login for headless environments. Use when the user says "login to gcloud", "gcloud auth login", "authenticate gcp", "connect google cloud", or when any Google Cloud operation fails with auth errors.
f5-sales-demo/marketplace · ★ 0 · DevOps & Infrastructure · score 71
Install: claude install-skill f5-sales-demo/marketplace
**Canonical skill URI**: `skill://gcloud:gcloud-auth` # Google Cloud CLI Authentication (Container-Adapted) This skill guides authentication for headless container environments where browser-based login may not be available. ## Authentication Methods ### Method 1: Service Account Key via Environment Variable (Recommended for Automation) Best for CI/CD and automated environments. Uses the `GOOGLE_APPLICATION_CREDENTIALS` environment variable pointing to a service account key file. **Prerequisites:** - Service account created with appropriate IAM roles - JSON key file downloaded and accessible in the container - `GOOGLE_APPLICATION_CREDENTIALS` set to the key file path **Command:** ```bash gcloud auth activate-service-account \ --key-file "$GOOGLE_APPLICATION_CREDENTIALS" ``` ### Method 2: Explicit Service Account Key File Use when the key file path is known but not set as an environment variable. **Command:** ```bash gcloud auth activate-service-account \ --key-file <path-to-key-file.json> ``` ### Method 3: Headless Browser Login (No Launch Browser) Use in container environments where a browser cannot open directly. Prints a URL for the user to visit in an external browser. **Command:** ```bash gcloud auth login --no-launch-browser ``` ### Method 4: Browser Login Works when a browser is available (VNC enabled or desktop environment). **Command:** ```bash gcloud auth login ``` ### Application Default Credentials For applications that use Google Cloud