-
Notifications
You must be signed in to change notification settings - Fork 1
Initial commit with base Dockerfile, entrypoint and compose. #1
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
base: main
Are you sure you want to change the base?
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.
Please look at comments, we might be able to solve the little issues before proposing a first version of the docker image.
You can find some help in the OpenLDAP LTB docker image from FusionIAM: https://gitlab.ow2.org/fusioniam/fusioniam/-/tree/master/build/rockylinux9/openldap-ltb
Dockerfile
Outdated
@@ -0,0 +1,68 @@ | |||
# Base Image | |||
FROM debian:stable-slim | |||
LABEL org.opencontainers.image.authors="Abhishek Pai" \ |
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.
Please add Worteks in authors
RUN cp slapd-cli-prompt /etc/bash_completion.d/ | ||
RUN cp slapd-ltb.service /lib/systemd/system/ | ||
RUN cp lload-ltb.service /lib/systemd/system/ | ||
|
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.
slapd-cli is included in Debian packages, you don't have to install it
|
||
# add to $PATH | ||
ENV PATH=/usr/local/openldap/bin:/usr/local/openldap/sbin:$PATH | ||
ENV SLAPD_CONF_DIR=/usr/local/openldap/etc/openldap/slapd.d/ |
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.
Why is it needed?
docker-compose.yaml
Outdated
- '389:389' | ||
- '636:636' | ||
volumes: | ||
- ./openldap-ltb:/openldap/ |
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.
Mounting the whole dir is useless.
We only need to mount data and cn=config dirs
docker-entrypoint.sh
Outdated
mv /usr/local/openldap/* /openldap/ | ||
|
||
# Link directories | ||
ln -s /openldap/* /usr/local/openldap/ |
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.
Don't understand the need to have /openldap/
|
||
# import config and data | ||
slapd-cli importldifconfigtemplate | ||
slapd-cli importdatatemplate |
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.
This will break existing conf and data
|
||
# start process | ||
slapd-cli start | ||
|
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 be run in foreground, either with slapd-cli debug, either with slapd command line
No description provided.