Accessing the Kubernetes Explorer
For easier management of Kubernetes resources, you can use the Kubernetes explorer, accessible from the VS Code Activity bar on the left under the Cloud Code view .
The Kubernetes Explorer is powered by
kubectl. It's an easier way to access
your Kubernetes clusters and run a variety of commands on them. With the Explorer,
you can carry out the following functions on your Kubernetes resources:
- Copy Resource Name: Copy the resource name to the clipboard.
- Describe: Run a
kubectl describeon the resource.
Delete: Delete the resource.
Resource specific actions
- Set as active cluster: Set specified cluster as active to use it as the default cluster.
- Open Dashboard: Open the Kubernetes Dashboard for the specified cluster.
- Set as active context: Set specified context as active to use it as the default context.
Add Secret as Environment Variable: Add an existing Kubernetes secret to the deployment as an environment variable.
Mount Secret as Volume: Mount an existing Kubernetes secret as a volume in the deployment's container.
- Stream Logs: Stream logs from a pod. If there are multiple containers in the pod, you will be asked to select one.
- View Logs: View logs from a pod. If there are multiple containers in the pod, you will be asked to select one.
- Stream Logs: Stream logs from a container.
- View Logs: View logs from a container.
- Get Terminal: Open an interactive terminal to the container.
For an external IP object, you can click on its Open Address button to open the address in a web browser.
- Clicking on a secret object will display the decoded secret as a file.