osd: add privileged support (back) to blkdevmapper securityContext (work-around) #9191
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.
Description of your changes:
The blockdevmapper securityContext was changed to request a minimal set of required capabilities for its operation and drop running as privileged.
While the base change works and is valid in terms of the container's copy operation, it turns out that OpenShift may require some additional configuration not currently covered by the limited securityContext and the capabilities granted.
To not break those OpenShift deployments, make the blkdevmapper securityContext listen to the ROOK_HOSTPATH_REQUIRES_PRIVILEGED flag again to set privileged mode.
This flag is true on OpenShift deployments and running as privileged works around the (missing) configuration problem for now.
To properly drop privileged completely some additional investigation needs to be done on OpenShift deployments without relying on privileged execution.
This resolves the immediate problem of #9186 but just running everything privileged is not and should not be the proper solution long-term.
According to @travisn in said issue, PR #9175 might be relevant here.
Which issue is resolved by this Pull Request:
Resolves #9186
Checklist:
make codegen
) has been run to update object specifications, if necessary.