Skip to content

Commit 3beeabb

Browse files
authored
Fix DEX UID on OCP (argoproj-labs#2216)
Signed-off-by: Oliver Gondža <ogondza@gmail.com>
1 parent 5eedcfe commit 3beeabb

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

controllers/argocd/dex.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,8 @@ func (r *ReconcileArgoCD) reconcileDexDeployment(cr *argoproj.ArgoCD) error {
422422
// otherwise it refuses to create the container (CreateContainerConfigError).
423423
dexSecCtx := argoutil.DefaultSecurityContext()
424424
dexImage := getDexContainerImage(cr)
425-
if strings.HasPrefix(dexImage, common.ArgoCDDefaultDexImage) {
425+
// Skip for OCP - let the cluster make sure it is within the range.
426+
if strings.HasPrefix(dexImage, common.ArgoCDDefaultDexImage) && !IsOpenShiftCluster() {
426427
dexUID := common.ArgoCDDefaultDexRunAsUser
427428
dexSecCtx.RunAsUser = &dexUID
428429
}

0 commit comments

Comments
 (0)