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
Change installation path to ~/.kubescape/bin #1147
Conversation
Signed-off-by: Hollow Man <hollowman@opensuse.org>
That's a good plan. Do we think people use this script to upgrade Kubescape? Do we need to remove older versions of kubescape from places that were already in the path, first? If I installed an old version the old way, and then a new version the new way, I might end up with an older version, earlier in the |
Signed-off-by: Hollow Man <hollowman@opensuse.org>
Just updated it to fix this issue. If the One thing to note that I don't know if |
I'm not so much worried as "user installed as root", I'm worried by "user ran the old script, which didn't install in /usr/local/bin but instead installed in whatever the first writable directory in the $PATH there was". It might be worth iterating through the $PATH and asking the user if they want to delete any
Was that what you wanted? |
Yeah, you are right! That's a kind of technical debt. Will work on this tomorrow.
Yes, exactly. I think that shouldn't be a problem as this is not something new. |
Signed-off-by: Hollow Man <hollowman@opensuse.org>
My only concern with scripts like this is we really really need to make sure |
Ah, yeah, that's really another problem. Will add that check before the deletion command as well. |
Signed-off-by: Hollow Man <hollowman@opensuse.org>
I think now this is ready to get merged as well. |
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 few shellcheck
nits
@HollowMan6 maybe at the same time you could address the other
Thanks in advance! |
@HollowMan6 also you probably need to amend locally to please the DCO :-/ |
Signed-off-by: Hollow Man <hollowman@opensuse.org>
Thank you! |
thanks @HollowMan6 ! |
Resolve #1015
Overview
The installation behavior now changes into the follows:
/usr/local/bin/
.~/.kubescape/bin
, and a message will be shown to user asking them to put that directory into PATH manually.