-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
Fix handling of installation prefix so that we don’t use /usr
under the prefix.
#14661
Conversation
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.
Should this:
Lines 914 to 915 in 5319b43
if [ -x "${NETDATA_PREFIX}/usr/libexec/netdata-switch-dashboard.sh" ]; then | |
"${NETDATA_PREFIX}/usr/libexec/netdata-switch-dashboard.sh" classic |
and also this:
Lines 1456 to 1458 in 5319b43
if [ -f "${NETDATA_PREFIX}/usr/libexec/netdata/plugins.d/go.d.plugin" ]; then | |
if command -v setcap 1>/dev/null 2>&1; then | |
run setcap "cap_net_admin+epi cap_net_raw=eip" "${NETDATA_PREFIX}/usr/libexec/netdata/plugins.d/go.d.plugin" |
be changed to
NETDATA_LIBEXECDIR
as well?
It generally works OK so far, but I want to do some more testing before approving it.
The first case needs to stay as-is (it’s there as a compatibility hack, though it can probably be removed at some point in the near future). The second case does actually need updated though, not sure how I missed it. |
5319b43
to
db44368
Compare
Rebased to pick up CI changes. |
Converting this to a draft because it still needs more work. |
@Ferroin How are you planning to handle existing installs? |
Handling of that is part of the reason this got switched to be a draft again. I’m trying to come up with a good solution for preserving the existing paths there (and ideally also a migration path for static installs, but that will probably be a separate PR from this one). |
28b4332
to
4defcbc
Compare
Rebased to pick up CI fixes. |
If installing to a prefix, we should _not_ be using `/usr` inside that prefix.
4defcbc
to
d12570c
Compare
Rebased to resolve merge conflicts. |
Closing in favor of #17308 |
Summary
If installing to a prefix, we should not be using
/usr
inside that prefix. Doing so causes all kinds of problems and makes things behave in ways users do not expect them to.Test Plan
This needs verification for both installs and updates on a variety of systems.
Additional Information
Fixes: #13242
This requires special handling around the merge as it is technically a breaking change.