Skip to content
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: runAsUser in yaml is unneeded as its set in the Dockerfile #546

Merged
merged 1 commit into from
Jul 10, 2024

Conversation

ThatsMrTalbot
Copy link
Contributor

This also fixes an issue in OpenShift where OpenShift wants you to use a certain range of UIDs that 1000 does not fall into:

.containers[0].runAsUser: Invalid value: 1000: must be in the ranges: [1000660000, 1000669999]

By not specifying an runAsUser in the yaml, OpenShift picks a appropriate UID for you:

$ kubectl get deployment venafi-kubernetes-agent | grep runAsUser
$ kubectl get pod venafi-kubernetes-agent-6b8f756ffb-rmb45 -o yaml | grep runAsUser
      runAsUser: 1000660000

Since the Dockerfile contains the USER directive this should have no effect on non OpenShift Kubernetes clusters.

This also fixes an issue in OpenShift where OpenShift wants you to use a certain range of UIDs that 1000 does not fall into. By not specifying an runAsUser in the yaml, OpenShift picks a appropriate UID for you.

Since the Dockerfile contains the USER directive this should have no effect on non OpenShift Kubernetes clusters.

Signed-off-by: Adam Talbot <[email protected]>
Copy link
Contributor

@SgtCoDFish SgtCoDFish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

Seems reasonable given the openshift situation!

@SgtCoDFish SgtCoDFish merged commit 6baaa57 into master Jul 10, 2024
8 checks passed
@SgtCoDFish SgtCoDFish deleted the fix/VC-34650-runas-breaks-openshift branch July 10, 2024 11:12
@ThatsMrTalbot ThatsMrTalbot mentioned this pull request Jul 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants