Add kubernetes Python library to sonic-mgmt container#25564
Merged
yxieca merged 1 commit intosonic-net:masterfrom Feb 25, 2026
Merged
Add kubernetes Python library to sonic-mgmt container#25564yxieca merged 1 commit intosonic-net:masterfrom
yxieca merged 1 commit intosonic-net:masterfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds Kubernetes tooling into the docker-sonic-mgmt container image to support kubesonic test automation workflows.
Changes:
- Add the
kubernetesPython client library to the container’s pip-installed dependencies. - Download and install a
kubectlbinary into/usr/local/bin.
Add kubernetes Python package to docker-sonic-mgmt for kubesonic test automation support. The Python library provides K8s API access for tests. Note: kubectl binary is not needed - tests use: - Python kubernetes library for API operations - minikube kubectl on vmhost for cluster management Signed-off-by: Dawei Huang <daweihuang@microsoft.com>
Collaborator
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
12 tasks
0b2f486 to
547a8f9
Compare
Collaborator
|
/azp run Azure.sonic-buildimage |
|
Azure Pipelines successfully started running 1 pipeline(s). |
isabelmsft
approved these changes
Feb 20, 2026
yxieca
approved these changes
Feb 25, 2026
Contributor
yxieca
left a comment
There was a problem hiding this comment.
Reviewed: simple dependency add; looks good.
FengPan-Frank
pushed a commit
to FengPan-Frank/sonic-buildimage
that referenced
this pull request
Mar 6, 2026
What is the motivation for this PR Enable kubesonic integration tests in sonic-mgmt; tests use the Python kubernetes client to interact with the K8s API. How did you do it Added kubernetes to the pip install list in the docker-sonic-mgmt Dockerfile. How did you verify/test it Build sonic-mgmt container and verify kubernetes package is installed: python -c "import kubernetes; print(kubernetes.__version__)" Signed-off-by: Dawei Huang <daweihuang@microsoft.com> Signed-off-by: Feng Pan <fenpan@microsoft.com>
dprital
pushed a commit
that referenced
this pull request
Mar 19, 2026
What is the motivation for this PR Enable kubesonic integration tests in sonic-mgmt; tests use the Python kubernetes client to interact with the K8s API. How did you do it Added kubernetes to the pip install list in the docker-sonic-mgmt Dockerfile. How did you verify/test it Build sonic-mgmt container and verify kubernetes package is installed: python -c "import kubernetes; print(kubernetes.__version__)" Signed-off-by: Dawei Huang <daweihuang@microsoft.com> Signed-off-by: dprital <drorp@nvidia.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add kubernetes Python package to docker-sonic-mgmt for kubesonic test automation support.
The Python library provides K8s API access for tests that verify SONiC's Kubernetes integration (kubesonic).
Note: kubectl binary is not needed - tests use:
Why I did it
Enable kubesonic integration tests in sonic-mgmt. The tests use Python kubernetes client to interact with the K8s cluster API.
Work item tracking
How I did it
Added
kubernetesto the pip install list in docker-sonic-mgmt Dockerfile.How to verify it
Build sonic-mgmt container and verify kubernetes package is installed:
python -c "import kubernetes; print(kubernetes.__version__)"Which release branch to backport (provide reason below if selected)
Tested branch (Please provide the tested image version)
Description for the changelog
Add kubernetes Python library to sonic-mgmt container for kubesonic test support.
Link to config_db schema for YANG module changes
N/A
A picture of a cute animal (not mandatory but encouraged)