docker-openldap: cannot deploy on OpenShift 4.x - no logs to tell why
I have a CRC VM running OpenShift 4.1.6.
I create a namespace “ldap” and then use a modified example kubernetes yaml to create an LDAP deployment. I say modified because I can’t use hostPath
(not allowed when deployed in this CRC openshift cluster), so I just changed the volumes to mount to an emptyDir:
volumes:
- name: ldap-data
emptyDir: {}
- name: ldap-config
emptyDir: {}
- name: ldap-certs
emptyDir: {}
I assume empty directories are ok, and that this should just start with all defaults and no initial data in the LDAP directory.
Everything else is the same as the current example yaml.
When I run oc create -f ldap-deployment.yaml -n ldap
, the pod tries to start but fails. But the problem is I have no way of knowing why. I see the pod status of “CrashLoopBackOff”. When I look at the logs, all I see are two lines:
*** CONTAINER_LOG_LEVEL = 3 (info)
*** Killing all processes...
If I edit the Deployment such that the env var LDAP_LOG_LEVEL has a value of “-1” (which should enable all debugging according to Section 5.2.1.2 here: https://www.openldap.org/doc/admin24/slapdconf2.html) I still only see those 2 lines.
So, in short, trying to install on OpenShift is failing and I’ve no idea why. 2 questions:
- How can I enable debug messages?
- How can I deploy on OpenShift 4?
About this issue
- Original URL
- State: open
- Created 5 years ago
- Reactions: 1
- Comments: 17 (4 by maintainers)
I hit exactly this issue at OCP, it can be solved by grant the openldap pod’s service account with anyuid SCC. I guess the arbitrary UID at OCP break this container.
The command is: