-
Notifications
You must be signed in to change notification settings - Fork 164
Add namespace validation to catch invalid names before build/deploy #3133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: RayyanSeliya <rayyanseliya786@gmail.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: RayyanSeliya The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
Hi @RayyanSeliya. Thanks for your PR. I'm waiting for a github.com member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
Signed-off-by: RayyanSeliya <rayyanseliya786@gmail.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3133 +/- ##
==========================================
+ Coverage 58.31% 59.01% +0.69%
==========================================
Files 134 134
Lines 17377 17404 +27
==========================================
+ Hits 10134 10271 +137
+ Misses 6302 6162 -140
- Partials 941 971 +30
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Signed-off-by: RayyanSeliya <rayyanseliya786@gmail.com>
|
Hey @gauron99 can u have alook when u have some moments am I doing right ? |
Changes
Adds DNS-1123 validation for namespace names before build/deploy operations. Invalid namespace names now fail immediately with clear error messages instead of proceeding through lengthy builds.
Implementation:
ValidateNamespace()function using Kubernetes DNS-1123 validation (pkg/utils/names.go)deployConfig.Validate()and error handling inrunDeploy()(cmd/deploy.go)ErrInvalidNamespaceerror type (pkg/functions/errors.go) with user-friendly CLI message/kind enhancement
Fixes #3132
Release Note