GCP Kubectl

Modified on Tue, 6 Jan at 10:41 AM


Overview

The GKE_Kubectl_Command step allows you to run kubectl commands directly against a Google Kubernetes Engine (GKE) cluster without needing to manually configure authentication or kubeconfig files.


Configuration Fields

FieldDescriptionExample
IntegrationThe GCP integration/connection to use for authenticationwiv-gcp
ProjectThe GCP project containing your GKE clusterwiv-dev (wiv-dev)
LocationThe region or zone where your cluster is deployedus-central1
Cluster NameThe name of your GKE clusterautopilot-cluster-1
Kubectl CommandThe kubectl command to execute get namespaces


How to Use

  1. Select your GCP integration from the dropdown
  2. Choose the GCP project that contains your cluster
  3. Enter the cluster's location (region for Autopilot/regional clusters, zone for zonal clusters)
  4. Enter the cluster name
  5. Type your kubectl command in the command field
  6. Click Run Step


Output Format

The step returns a JSON object containing:

{  "cluster_name": "autopilot-cluster-1",  "location": "us-central1",  "output": "<kubectl command output>",  "project_id": "wiv-dev",  "status": "success" }


Example Commands

CommandDescription
get namespacesList all namespaces
get pods -AList all pods across all namespaces
get nodesList cluster nodes
get deployments -n defaultList deployments in default namespace
describe pod <pod-name> -n <namespace>Get details about a specific pod
logs <pod-name> -n <namespace>View pod logs


Notes

  • The step handles GKE authentication automatically using the selected integration
  • Execution time varies based on the command (shown in the results header)
  • Previous results are preserved for reference

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article