microsoft / microsoft/vscode-remote-release

Override kubectl exec command

Open
#6,413 4 comments 0 reactions 1 assignee View on GitHub

@chrmarti is already working on this.

Since Mar 7, 2022.

containers feature-request
Dominant language
Dockerfile
Stars
4.2k
Forks
470
Avg merge
1d 1h
Merged PRs (30d)
1

Description

When attaching to a Kubernetes pod in Vscode, the following command is run:
kubectl exec -it <pod-name> --container <name> -- /bin/sh -c VSCODE_REMOTE_CONTAINERS_SESSION=<session-id> /bin/sh

For my particular use case, it would be helpful to run something other than /bin/sh and am wondering if it would be possible to expose an argument that enables substituting /bin/sh with a user specified command. The Vscode remote URI would work for my purpose if it supported a command argument like so:
vscode://vscode-remote/k8s-container+podname=<pod-name>+name=<name>+command=<custom-command>/

This would resolve the need for: https://github.com/microsoft/vscode-remote-release/issues/5165

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.