conversations
listlengths
2
2
[ { "from": "human", "value": "Create a namespace via the `kubectl-create` command" }, { "from": "gpt", "value": "`kubectl create namespace {{namespace_name}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl delete`." }, { "from": "gpt", "value": "Delete Kubernetes resources.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#delete>.\n" } ]
[ { "from": "human", "value": "Delete a specific pod via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete pod {{pod_name}}`" } ]
[ { "from": "human", "value": "Delete a specific deployment via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete deployment {{deployment_name}}`" } ]
[ { "from": "human", "value": "Delete a specific node via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete node {{node_name}}`" } ]
[ { "from": "human", "value": "Delete all pods in a specified namespace via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete pods --all --namespace {{namespace}}`" } ]
[ { "from": "human", "value": "Delete all deployments and services in a specified namespace via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete deployments,services --all --namespace {{namespace}}`" } ]
[ { "from": "human", "value": "Delete all nodes via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete nodes --all`" } ]
[ { "from": "human", "value": "Delete resources defined in a YAML manifest via the `kubectl-delete` command" }, { "from": "gpt", "value": "`kubectl delete --filename {{path/to/manifest.yaml}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl describe`." }, { "from": "gpt", "value": "Show details of Kubernetes objects and resources.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#describe>.\n" } ]
[ { "from": "human", "value": "Show details of pods in a namespace via the `kubectl-describe` command" }, { "from": "gpt", "value": "`kubectl describe pods {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Show details of nodes in a namespace via the `kubectl-describe` command" }, { "from": "gpt", "value": "`kubectl describe nodes {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Show the details of a specific pod in a namespace via the `kubectl-describe` command" }, { "from": "gpt", "value": "`kubectl describe pods {{pod_name}} {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Show the details of a specific node in a namespace via the `kubectl-describe` command" }, { "from": "gpt", "value": "`kubectl describe nodes {{node_name}} {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Show details of Kubernetes objects defined in a YAML manifest file via the `kubectl-describe` command" }, { "from": "gpt", "value": "`kubectl describe {{[-f|--file]}} {{path/to/manifest.yaml}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl edit`." }, { "from": "gpt", "value": "Edit Kubernetes resources.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#edit>.\n" } ]
[ { "from": "human", "value": "Edit a pod via the `kubectl-edit` command" }, { "from": "gpt", "value": "`kubectl edit pod/{{pod_name}}`" } ]
[ { "from": "human", "value": "Edit a deployment via the `kubectl-edit` command" }, { "from": "gpt", "value": "`kubectl edit deployment/{{deployment_name}}`" } ]
[ { "from": "human", "value": "Edit a service via the `kubectl-edit` command" }, { "from": "gpt", "value": "`kubectl edit svc/{{service_name}}`" } ]
[ { "from": "human", "value": "Edit a resource using a specific editor via the `kubectl-edit` command" }, { "from": "gpt", "value": "`KUBE_EDITOR={{nano}} kubectl edit {{resource}}/{{resource_name}}`" } ]
[ { "from": "human", "value": "Edit a resource in JSON format via the `kubectl-edit` command" }, { "from": "gpt", "value": "`kubectl edit {{resource}}/{{resource_name}} --output json`" } ]
[ { "from": "human", "value": "Tell me about `kubectl expose`." }, { "from": "gpt", "value": "Expose a resource as a new Kubernetes service.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#expose>.\n" } ]
[ { "from": "human", "value": "Create a service for a resource, which will be served from container port to node port via the `kubectl-expose` command" }, { "from": "gpt", "value": "`kubectl expose {{resource_type}} {{resource_name}} --port={{node_port}} --target-port={{container_port}}`" } ]
[ { "from": "human", "value": "Create a service for a resource identified by a file via the `kubectl-expose` command" }, { "from": "gpt", "value": "`kubectl expose -f {{path/to/file.yml}} --port={{node_port}} --target-port={{container_port}}`" } ]
[ { "from": "human", "value": "Create a service with a name, to serve to a node port which will be same for container port via the `kubectl-expose` command" }, { "from": "gpt", "value": "`kubectl expose {{resource_type}} {{resource_name}} --port={{node_port}} --name={{service_name}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl get`." }, { "from": "gpt", "value": "Get Kubernetes objects and resources.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#get>.\n" } ]
[ { "from": "human", "value": "Get all namespaces in the current cluster via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get namespaces`" } ]
[ { "from": "human", "value": "Get nodes in a specified namespace via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get nodes {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Get pods in a specified namespace via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get pods {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Get deployments in a specified namespace via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get deployments {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Get services in a specified namespace via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get services {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Get all resources in a specified namespace via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get all {{[-n|--namespace]}} {{namespace}}`" } ]
[ { "from": "human", "value": "Get Kubernetes objects defined in a YAML manifest file via the `kubectl-get` command" }, { "from": "gpt", "value": "`kubectl get {{[-f|--file]}} {{path/to/manifest.yaml}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl label`." }, { "from": "gpt", "value": "Label Kubernetes resources.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#label>.\n" } ]
[ { "from": "human", "value": "Label a pod via the `kubectl-label` command" }, { "from": "gpt", "value": "`kubectl label pod {{pod_name}} {{key}}={{value}}`" } ]
[ { "from": "human", "value": "Update a pod label by overwriting the existing value via the `kubectl-label` command" }, { "from": "gpt", "value": "`kubectl label --overwrite pod {{pod_name}} {{key}}={{value}}`" } ]
[ { "from": "human", "value": "Label all pods in the namespace via the `kubectl-label` command" }, { "from": "gpt", "value": "`kubectl label pods --all {{key}}={{value}}`" } ]
[ { "from": "human", "value": "Label a pod identified by the pod definition file via the `kubectl-label` command" }, { "from": "gpt", "value": "`kubectl label -f {{pod_definition_file}} {{key}}={{value}}`" } ]
[ { "from": "human", "value": "Remove the label from a pod via the `kubectl-label` command" }, { "from": "gpt", "value": "`kubectl label pod {{pod_name}} {{key}}-`" } ]
[ { "from": "human", "value": "Tell me about `kubectl logs`." }, { "from": "gpt", "value": "Show logs for containers in a pod.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#logs>.\n" } ]
[ { "from": "human", "value": "Show logs for a single-container pod via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs {{pod_name}}`" } ]
[ { "from": "human", "value": "Show logs for a specified container in a pod via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs --container {{container_name}} {{pod_name}}`" } ]
[ { "from": "human", "value": "Show logs for all containers in a pod via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs --all-containers={{true}} {{pod_name}}`" } ]
[ { "from": "human", "value": "Stream pod logs via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs --follow {{pod_name}}`" } ]
[ { "from": "human", "value": "Show pod logs newer than a relative time like `10s`, `5m`, or `1h` via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs --since={{relative_time}} {{pod_name}}`" } ]
[ { "from": "human", "value": "Show the 10 most recent logs in a pod via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs --tail={{10}} {{pod_name}}`" } ]
[ { "from": "human", "value": "Show all pod logs for a given deployment via the `kubectl-logs` command" }, { "from": "gpt", "value": "`kubectl logs deployment/{{deployment_name}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl`." }, { "from": "gpt", "value": "Command-line interface for running commands against Kubernetes clusters.\nSome subcommands such as `run` have their own usage documentation.\nMore information: <https://kubernetes.io/docs/reference/kubectl/>.\n"...
[ { "from": "human", "value": "List information about a resource with more details via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl get {{pod|service|deployment|ingress|...}} -o wide`" } ]
[ { "from": "human", "value": "Update specified pod with the label 'unhealthy' and the value 'true' via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl label pods {{name}} unhealthy=true`" } ]
[ { "from": "human", "value": "List all resources with different types via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl get all`" } ]
[ { "from": "human", "value": "Display resource (CPU/Memory/Storage) usage of nodes or pods via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl top {{pod|node}}`" } ]
[ { "from": "human", "value": "Print the address of the master and cluster services via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl cluster-info`" } ]
[ { "from": "human", "value": "Display an explanation of a specific field via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl explain {{pods.spec.containers}}`" } ]
[ { "from": "human", "value": "Print the logs for a container in a pod or specified resource via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl logs {{pod_name}}`" } ]
[ { "from": "human", "value": "Run command in an existing pod via the `kubectl` command" }, { "from": "gpt", "value": "`kubectl exec {{pod_name}} -- {{ls /}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl replace`." }, { "from": "gpt", "value": "Replace a resource by file or `stdin`.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#replace>.\n" } ]
[ { "from": "human", "value": "Replace the resource using the resource definition file via the `kubectl-replace` command" }, { "from": "gpt", "value": "`kubectl replace -f {{path/to/file.yml}}`" } ]
[ { "from": "human", "value": "Replace the resource using the input passed into `stdin` via the `kubectl-replace` command" }, { "from": "gpt", "value": "`kubectl replace -f -`" } ]
[ { "from": "human", "value": "Force replace, delete and then re-create the resource via the `kubectl-replace` command" }, { "from": "gpt", "value": "`kubectl replace --force -f {{path/to/file.yml}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl rollout`." }, { "from": "gpt", "value": "Manage the rollout of a Kubernetes resource (deployments, daemonsets, and statefulsets).\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#rollout>.\n" } ]
[ { "from": "human", "value": "Start a rolling restart of a resource via the `kubectl-rollout` command" }, { "from": "gpt", "value": "`kubectl rollout restart {{resource_type}}/{{resource_name}}`" } ]
[ { "from": "human", "value": "Watch the rolling update status of a resource via the `kubectl-rollout` command" }, { "from": "gpt", "value": "`kubectl rollout status {{resource_type}}/{{resource_name}}`" } ]
[ { "from": "human", "value": "Roll back a resource to the previous revision via the `kubectl-rollout` command" }, { "from": "gpt", "value": "`kubectl rollout undo {{resource_type}}/{{resource_name}}`" } ]
[ { "from": "human", "value": "View the rollout history of a resource via the `kubectl-rollout` command" }, { "from": "gpt", "value": "`kubectl rollout history {{resource_type}}/{{resource_name}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl run`." }, { "from": "gpt", "value": "Run pods in Kubernetes. Specifies pod generator to avoid deprecation error in some K8S versions.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#run>.\n" } ]
[ { "from": "human", "value": "Run an nginx pod and expose port 80 via the `kubectl-run` command" }, { "from": "gpt", "value": "`kubectl run {{nginx-dev}} --image=nginx --port 80`" } ]
[ { "from": "human", "value": "Run an nginx pod, setting the TEST_VAR environment variable via the `kubectl-run` command" }, { "from": "gpt", "value": "`kubectl run {{nginx-dev}} --image=nginx --env=\"{{TEST_VAR}}={{testing}}\"`" } ]
[ { "from": "human", "value": "Show API calls that would be made to create an nginx container via the `kubectl-run` command" }, { "from": "gpt", "value": "`kubectl run {{nginx-dev}} --image=nginx --dry-run={{none|server|client}}`" } ]
[ { "from": "human", "value": "Run an Ubuntu pod interactively, never restart it, and remove it when it exits via the `kubectl-run` command" }, { "from": "gpt", "value": "`kubectl run {{temp-ubuntu}} --image=ubuntu:22.04 --restart=Never --rm -- /bin/bash`" } ]
[ { "from": "human", "value": "Run an Ubuntu pod, overriding the default command with echo, and specifying custom arguments via the `kubectl-run` command" }, { "from": "gpt", "value": "`kubectl run {{temp-ubuntu}} --image=ubuntu:22.04 --command -- echo {{argument1 argument2 ...}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl scale`." }, { "from": "gpt", "value": "Set a new size for a deployment, replica set, replication controller, or stateful set.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#scale>.\n" } ]
[ { "from": "human", "value": "Scale a replica set via the `kubectl-scale` command" }, { "from": "gpt", "value": "`kubectl scale --replicas={{number_of_replicas}} rs/{{replica_name}}`" } ]
[ { "from": "human", "value": "Scale a resource identified by a file via the `kubectl-scale` command" }, { "from": "gpt", "value": "`kubectl scale --replicas={{number_of_replicas}} -f {{path/to/file.yml}}`" } ]
[ { "from": "human", "value": "Scale a deployment based on current number of replicas via the `kubectl-scale` command" }, { "from": "gpt", "value": "`kubectl scale --current-replicas={{current_replicas}} --replicas={{number_of_replicas}} deployment/{{deployment_name}}`" } ]
[ { "from": "human", "value": "Tell me about `kubectl taint`." }, { "from": "gpt", "value": "Update the taints on nodes.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#taint>.\n" } ]
[ { "from": "human", "value": "Apply taint to a node via the `kubectl-taint` command" }, { "from": "gpt", "value": "`kubectl taint nodes {{node_name}} {{label_key}}={{label_value}}:{{effect}}`" } ]
[ { "from": "human", "value": "Remove taint from a node via the `kubectl-taint` command" }, { "from": "gpt", "value": "`kubectl taint nodes {{node_name}} {{label_key}}:{{effect}}-`" } ]
[ { "from": "human", "value": "Remove all taints from a node via the `kubectl-taint` command" }, { "from": "gpt", "value": "`kubectl taint nodes {{node_name}} {{label_key}}-`" } ]
[ { "from": "human", "value": "Tell me about `kubectl wait`." }, { "from": "gpt", "value": "Wait for resource(s) to reach a certain state.\nMore information: <https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#wait>.\n" } ]
[ { "from": "human", "value": "Wait for a deployment to become available via the `kubectl-wait` command" }, { "from": "gpt", "value": "`kubectl wait --for=condition=available deployment/{{deployment_name}}`" } ]
[ { "from": "human", "value": "Wait for all pods with a certain [l]abel to be ready via the `kubectl-wait` command" }, { "from": "gpt", "value": "`kubectl wait --for=condition=ready pod {{[-l|--selector]}} {{label_key}}={{label_value}}`" } ]
[ { "from": "human", "value": "Wait for a pod to be deleted via the `kubectl-wait` command" }, { "from": "gpt", "value": "`kubectl wait --for=delete pod {{pod_name}}`" } ]
[ { "from": "human", "value": "Wait for a job to complete, within 120 seconds (if the condition isn't met on time, the exit status will be unsuccessful) via the `kubectl-wait` command" }, { "from": "gpt", "value": "`kubectl wait --for=condition=complete job/{{job_name}} --timeout 120s`" } ]
[ { "from": "human", "value": "Tell me about `kubectx`." }, { "from": "gpt", "value": "Utility to manage and switch between `kubectl` contexts.\nMore information: <https://github.com/ahmetb/kubectx>.\n" } ]
[ { "from": "human", "value": "List the contexts via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx`" } ]
[ { "from": "human", "value": "Switch to a named context via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx {{name}}`" } ]
[ { "from": "human", "value": "Switch to the previous context via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx -`" } ]
[ { "from": "human", "value": "Rename a named context via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx {{alias}}={{name}}`" } ]
[ { "from": "human", "value": "Show the current named context via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx -c`" } ]
[ { "from": "human", "value": "Delete a named context via the `kubectx` command" }, { "from": "gpt", "value": "`kubectx -d {{name}}`" } ]
[ { "from": "human", "value": "Tell me about `kube-fzf`." }, { "from": "gpt", "value": "Shell commands for command-line fuzzy searching of Kubernetes Pods.\nSee also `kubectl` for related commands.\nMore information: <https://github.com/thecasualcoder/kube-fzf>.\n" } ]
[ { "from": "human", "value": "Get pod details (from current namespace) via the `kube-fzf` command" }, { "from": "gpt", "value": "`findpod`" } ]
[ { "from": "human", "value": "Get pod details (from all namespaces) via the `kube-fzf` command" }, { "from": "gpt", "value": "`findpod -a`" } ]
[ { "from": "human", "value": "Describe a pod via the `kube-fzf` command" }, { "from": "gpt", "value": "`describepod`" } ]
[ { "from": "human", "value": "Tail pod logs via the `kube-fzf` command" }, { "from": "gpt", "value": "`tailpod`" } ]
[ { "from": "human", "value": "Exec into a pod's container via the `kube-fzf` command" }, { "from": "gpt", "value": "`execpod {{shell_command}}`" } ]
[ { "from": "human", "value": "Port-forward a pod via the `kube-fzf` command" }, { "from": "gpt", "value": "`pfpod {{port_number}}`" } ]
[ { "from": "human", "value": "Tell me about `kubens`." }, { "from": "gpt", "value": "Utility to switch between Kubernetes namespaces.\nMore information: <https://github.com/ahmetb/kubectx>.\n" } ]
[ { "from": "human", "value": "List the namespaces via the `kubens` command" }, { "from": "gpt", "value": "`kubens`" } ]