Skip to content

Add exec to pod method in KubeClient#24

Merged
name212 merged 4 commits intomainfrom
add-pod-executor
Apr 29, 2026
Merged

Add exec to pod method in KubeClient#24
name212 merged 4 commits intomainfrom
add-pod-executor

Conversation

@name212
Copy link
Copy Markdown
Member

@name212 name212 commented Apr 28, 2026

In kube:

  • add to KubeClient Exec method for run command in pod container.
    It needs for hide implementation details, because exec in pod client-go method require rest config.
    We can get it only for internal client, not interface
  • add NewFakeKubeProviderWithExec and NewFakeKubeProviderInitializerWithPodExec for create fake client with fake executor. For testing purposes you can implement your own PodCommandExecutor and pass it.
  • fix potential panic with initialization for ErrorKubernetesClient

name212 added 4 commits April 28, 2026 23:04
Signed-off-by: Nikolay Mitrofanov <nikolay.mitrofanov@flant.com>
Signed-off-by: Nikolay Mitrofanov <nikolay.mitrofanov@flant.com>
Signed-off-by: Nikolay Mitrofanov <nikolay.mitrofanov@flant.com>
Signed-off-by: Nikolay Mitrofanov <nikolay.mitrofanov@flant.com>
@name212 name212 changed the title Add pod executor Add exec to pod method in KubeClient Apr 28, 2026
@name212 name212 merged commit bc7b448 into main Apr 29, 2026
4 checks passed
@name212 name212 deleted the add-pod-executor branch April 29, 2026 07:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant