google-cloud-recipe-onboarding
Guides a developer's first steps on Google Cloud, covering account creation, billing setup, project management, and deploying a first resource. Use when a new developer wants to initialize their first Google Cloud project, configure billing, and verify deployment. Don't use for enterprise organization setup (use Google Cloud Setup guided flow for that instead). Don't use for complex multi-project architectures.
google · 已有 AI 审核记录
安装与使用
运行命令前先阅读来源与依赖说明。复制命令不会自动安装或执行。
npx skills add google/skills --skill google-cloud-recipe-onboarding技能说明
name: google-cloud-recipe-onboarding metadata: category: GettingStarted description: >- Guides a developer's first steps on Google Cloud, covering account creation, billing setup, project management, and deploying a first resource. Use when a new developer wants to initialize their first Google Cloud project, configure billing, and verify deployment. Don't use for enterprise organization setup (use Google Cloud Setup guided flow for that instead). Don't use for complex multi-project architectures.
Onboarding to Google Cloud
This skill provides a streamlined, non-interactive "happy path" for a singleton developer to get started with Google Cloud. It covers everything from environment verification and authentication to project selection, billing account linkage, and downstream safety chaining.
[!IMPORTANT] For autonomous agents executing this skill:
- Check-Before-Mutate Audits: Always perform silent pre-execution state audits prior to proposing or executing any project or billing changes.
- Single-Question Policy: Ask the user for exactly one operational parameter or confirmation at a time during interactive execution.
- Non-Interactive Output: Append non-interactive overrides (
--quiet,--format="json") to all mutation commands to guarantee deterministic, machine-parseable outputs and prevent terminal hangs.- First Turn Interaction Rules (Trigger Turn): When the developer first triggers this skill with a general onboarding request (e.g. says "I want to get started with Google Cloud"):
- Preamble Guidance: Proactively include a short orienting preamble guiding the developer to create a Google Cloud account (pointing to the console at
https://console.cloud.google.com/) and rungcloud auth loginto authorize their workstation, even if they appear to be already logged in.- First Turn Single-Question: Perform pre-flight audits silently, but do not present a complete parameters summary table or ask for final consent in the first turn. Instead, ask the developer exactly one initial operational question (e.g., "Would you like to reuse an existing active project, or create a brand new one?"). Note: If the developer's initial prompt explicitly states "I approve the onboarding configuration", "Let's proceed with onboarding", or requests a dry-run plan (e.g., "Show me the exact plan or dry-run commands"), bypass the general preamble and initial question, and proceed directly to the requested step.
Overview
For an individual developer, onboarding to Google Cloud involves verifying local terminal tools, establishing an authenticated session, selecting or instantiating a workspace (Project), and linking it to an active billing account. Google Cloud offers a Free Tier and a Free Trial with $300 in credits for first-time users. Learn more here.
Prerequisites
- A personal Google Account (e.g.,
@gmail.com) or Google Workspace / Cloud Identity account. - A valid payment method (credit card or bank account) required for identity verification and to activate the $300 Free Trial credit introduced in the Overview.
Steps
Section 1: Verify Host Tooling Setup
Before soliciting input or proposing mutations, silently audit the host system's active tooling and environment status.
-
Check if the
gcloudCLI binary is installed and accessible:which gcloud -
Check if there is an active authenticated identity session:
gcloud auth list --format="json" -
If the pre-execution audit for
which gcloudreturns a valid path, proceed directly to Section 2: Authenticate and Route Session. -
If the binary is missing, halt execution and direct the agent/developer to the gcloud skill or official Google Cloud CLI Installation Guide for setup and authentication instructions before retrying.
Section 2: Authenticate and Route Session
Authorize the gcloud CLI to access Google Cloud using the developer's Google Account, and verify that the account is appropriate for standalone developer onboarding.
-
Execute Credentials Authentication:
gcloud auth login[!IMPORTANT] New User / Unauthenticated Guidance: If the pre-execution state audits or command failures confirm that the developer is unauthenticated (e.g.,
gcloud auth listis empty or active credentials are missing):- Guide them to create a Google Cloud account by navigating to the Google Cloud Console.
- Instruct them to execute the
gcloud auth logincommand to authorize their local workstation terminal session. - Do not attempt project creation or resource configuration until authentication is completed successfully.
-
Verify Active Identity:
gcloud config get-value account --format="json" -
Programmatic Enterprise Routing Guardrail: Before proceeding, verify if the account is bound to a corporate organization, as enterprise setups must follow a different architecture:
gcloud organizations list --format="json"- Note that new Free Trial accounts automatically receive a Self-Owned Organization (SOO). To distinguish between a personal Free Trial account and an enterprise organization, inspect the JSON output:
- Enterprise Organization (Halt Execution): If the output list contains an organization node where
owner.directoryCustomerIdis present (confirming a domain-verified Google Workspace or Cloud Identity organization), or if the user's prompt explicitly mentions corporate landing zones
- Enterprise Organization (Halt Execution): If the output list contains an organization node where
- Note that new Free Trial accounts automatically receive a Self-Owned Organization (SOO). To distinguish between a personal Free Trial account and an enterprise organization, inspect the JSON output: