-
Notifications
You must be signed in to change notification settings - Fork 5
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
Get namespace from config file #140
Conversation
Signed-off-by: David Wertenteil <[email protected]>
PR Analysis
How to use
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
just a nit
Signed-off-by: David Wertenteil <[email protected]>
Summary:
|
PR Type:
Refactoring
PR Description:
This pull request refactors the way the namespace is retrieved from the configuration file. Instead of hardcoding the default namespace and using an environment variable, the namespace is now passed as an argument to the
CreateStorageNoCache
andCreateFakeStorageNoCache
functions. This change improves the flexibility and maintainability of the code.PR Main Files Walkthrough:
files:
main.go
: The namespace is now passed as an argument to theCreateStorageNoCache
function.pkg/storage/v1/storage_nocache.go
: TheCreateStorageNoCache
andCreateFakeStorageNoCache
functions now accept the namespace as an argument. ThegetNamespace
function and thedefaultNamespace
constant have been removed.pkg/storage/v1/storage_test.go
: The tests have been updated to pass the namespace as an argument to theCreateFakeStorageNoCache
function. The hardcoded namespace in the tests has been replaced with a string literal "kubescape".User Description:
Overview