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

ignore set -e at grep SLAPD_ #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

ignore set -e at grep SLAPD_ #18

wants to merge 1 commit into from

Conversation

tetsuyainfra
Copy link

Because "set -e option in entrypoint.sh"
if env | grep SLAPD_ (don't set SLAPD_* env) returned an error, shell script stops.

// Reproduce commands
docker volume create --name etc_ldap
docker volume create --name var_ldap

// 1st execution 
docker run -d \
  -e SLAPD_PASSWORD=mysecretpassword  \
  -e SLAPD_DOMAIN=ldap.example.org    \
  -v etc_ldap:/etc/ldap               \
  -v var_ldap:/var/lib/ldap           \
  dinkel/openldap

// 2nd execution ends immediately
docker run -d \
  -v etc_ldap:/etc/ldap               \
  -v var_ldap:/var/lib/ldap           \
  dinkel/openldap
// OR 
docker run -it \
  -v etc_ldap:/etc/ldap               \
  -v var_ldap:/var/lib/ldap           \
  dinkel/openldap

@bersace
Copy link

bersace commented Jun 23, 2017

Why not use bashism ? :)

$ echo ${!SSH_*}
SSH_AGENT_PID SSH_AUTH_SOCK

fedde-s added a commit to fedde-s/docker-openldap that referenced this pull request Sep 22, 2017
ignore set -e at grep SLAPD_

Because "set -e option in entrypoint.sh"
if `env | grep SLAPD_` (don't set SLAPD_* env) returned an error, shell
script stops.
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.

None yet

2 participants