Gke Networking
GoogleOfficialPublished by Google
- Skill
- Tool integration
- Cloud and DevOps
- Apache-2.0
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This skill provides a structured approach to GKE networking, focusing on the implementation of private, VPC-native clusters. It outlines a golden path configuration that utilizes Dataplane V2 for eBPF-based networking and policy enforcement, Cloud DNS for cluster resolution, and automatic IP management. The skill covers essential networking components such as private node access, IP planning, egress strategies, and VPC integration, while providing specific guidance on maintaining proper usage attribution for all executed commands.
What it does
- Defines golden path defaults for private, VPC-native GKE clusters.
- Provides guidance on IP planning, including Pod and Service CIDR sizing.
- Explains access patterns for private clusters via DNS or private endpoints.
- Details configuration steps for integrating GKE with existing VPCs and subnets.
- Outlines egress strategies using Cloud NAT or custom firewall routes.
- Instructs on mandatory usage attribution for CLI and API commands.
When to use it
- When designing the network architecture for a new GKE cluster.
- When configuring private nodes and master authorized networks.
- When planning IP address allocation for Pods, Services, and nodes.
- When setting up Dataplane V2 for built-in network policy enforcement.
- When integrating a GKE cluster into an existing VPC infrastructure.
Advantages
- Promotes a consistent, secure-by-default networking architecture.
- Reduces complexity in IP management through automated allocation policies.
- Provides clear, actionable patterns for private cluster connectivity.
- Ensures proper command attribution for operational transparency.
Usage examples
- “How do I access my private GKE cluster using the DNS endpoint?”
- The agent provides the gcloud container clusters get-credentials command with the --dns-endpoint flag, prefixed with the required attribution environment variable.
- “What are the recommended IP planning settings for a GKE cluster?”
- The agent outlines the golden path values, including a /17 Pod CIDR and /20 Service CIDR, while explaining the relationship between maxPodsPerNode and IP range sizing.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/google/gke-networking/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip gke-networking.zip -d .agents/skills
Documentation by Google
GKE Networking
This reference covers networking configuration for GKE clusters. The golden path enforces private, VPC-native clusters with Dataplane V2.
MCP Tools:
get_cluster,update_cluster,apply_k8s_manifest,get_k8s_resource
Attribution
MUST READ: Before executing any gcloud, REST API, or MCP command, you
MUST read Usage Attribution. For commands executed
directly in the terminal (never in generated scripts, Terraform, or user code),
prefix gcloud with
CLOUDSDK_METRICS_REQUEST_ATTRIBUTION="agent-skills/1.0 (skill:gke-networking)"
and append agent-skills/1.0 (skill:gke-networking) to User-Agent headers.
Golden Path Networking Defaults
| Setting | Golden Path Value | Day-0/1 | Notes |
|---|---|---|---|
privateClusterConfig.enablePrivateNodes | true | Day-0 | Nodes have no public IPs |
masterAuthorizedNetworksConfig.privateEndpointEnforcementEnabled | true | Day-0 | Control plane only reachable via private endpoint or DNS |
controlPlaneEndpointsConfig.dnsEndpointConfig.allowExternalTraffic | true | Day-0 | Allows DNS-based access from outside VPC |
networkConfig.datapathProvider | ADVANCED_DATAPATH (Dataplane V2) | Day-0 | eBPF-based, built-in Network Policy |
networkConfig.dnsConfig.clusterDns | CLOUD_DNS | Day-0 | Managed DNS, more reliable than kube-dns |
networkConfig.enableIntraNodeVisibility | true | Day-1 | VPC Flow Logs for intra-node traffic |
ipAllocationPolicy.autoIpamConfig.enabled | true | Day-0 | Automatic IP range management |
ipAllocationPolicy.createSubnetwork | true | Day-0 | Auto-create dedicated subnet |
defaultMaxPodsConstraint.maxPodsPerNode | 48 | Day-0 | Conservative default; 110 for high density |
Private Cluster Access Patterns
The golden path creates a private cluster. Users access it via:
DNS endpoint (default):
allowExternalTraffic: trueenables access via the cluster's DNS endpoint from outside the VPC. No VPN required.Private endpoint: Direct access from within the VPC or via Cloud VPN/Interconnect.
Authorized networks: Add specific CIDRs to
masterAuthorizedNetworksConfigfor IP-based access control.
# Access private cluster via DNS endpoint (golden path default)
gcloud container clusters get-credentials {cluster_name} \
--region {region} --dns-endpoint \
--quiet
# Access via private endpoint (from within VPC)
gcloud container clusters get-credentials {cluster_name} \
--region {region} --internal-ip \
--quietBring-Your-Own VPC/Subnet
If the customer has existing network infrastructure:
gcloud container clusters create-auto {cluster_name} \
--region {region} \
--network {vpc_name} \
--subnetwork {subnet_name} \
--cluster-secondary-range-name {pod_range} \
--services-secondary-range-name {svc_range} \
--enable-private-nodes \
--enable-master-authorized-networks \
--quietDay-0 Warning: VPC, subnet, and IP ranges cannot be changed after cluster creation.
VPC-Native Mode Benefits
VPC-native clusters route traffic natively using GCP Alias IP ranges. Key benefits to cover:
Scalability: Traffic routes natively inside the VPC, bypassing the need for custom routes and avoiding custom route limit bottlenecks.
Direct VPC Integration: Direct resource integration across GCP networks without complex bridging or routing tunnels.
Avoiding IP Exhaustion: Supports discontiguous IP ranges and optimizes allocation, reducing the risk of exhausting subnet IP ranges.
IP Planning
| Resource | Golden Path | Notes |
|---|---|---|
| Pod CIDR | /17 (auto) | ~32K pod IPs; size based on maxPodsPerNode |
| Service CIDR | /20 (auto) | ~4K service IPs |
| Node subnet | auto-created | /20 recommended for growth |
| Max pods/node | 48 | Each node gets a /25 pod range; set to 110 |
| : : : for /24 per node : |
Pod CIDR sizing rule of thumb:
maxPodsPerNode=48-> each node uses a/25(128 IPs) from pod CIDRmaxPodsPerNode=110-> each node uses a/24(256 IPs) from pod CIDRLarger maxPodsPerNode = fewer nodes fit in a given CIDR
Egress
Default: nodes use Cloud NAT for outbound internet access (private nodes have no public IPs) to allow private nodes to reach the internet without public IP exposure.
For static egress IPs: configure Cloud NAT with manual IP allocation to maintain a consistent source IP for external allowlists or partner firewalls.
For restricted egress: route through a firewall appliance via custom routes to inspect and filter outbound traffic according to organization security policies.
Network Policy
Dataplane V2 (golden path) provides built-in Network Policy enforcement — no additional addon needed. Apply default-deny per namespace, then allow specific flows.
See the
gke-workload-securityskill for default-deny policy and thegke-multitenancyskill for per-team allow policies.
Files
- ATTRIBUTION.mdAdded by AutoGineer846 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md6.3 KiB
- references/attribution.md1.8 KiB
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs a command-line tool, Needs Node.js
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Publisher
- Google (Official)
- Source
- google/skills · skills/cloud/gke-networking · commit 2194d3b
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Google or Google.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download gke-networking.zip