mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

Kevin McCormack
13.43.2018 0ccc6f7b4bff191f475fec7ac069f49e27eb5e69
Update Dockerfile

- Add ARG option to add base entry
- Reduce line lengths
1 files modified
11 ■■■■ changed files
opendj-packages/opendj-docker/Dockerfile 11 ●●●● patch | view | raw | blame | history
opendj-packages/opendj-docker/Dockerfile
@@ -2,6 +2,8 @@
MAINTAINER Open Identity Platform Community <open-identity-platform-opendj@googlegroups.com>
ARG ADD_BASE_ENTRY="--addBaseEntry"
ARG PORT=1389
ARG LDAPS_PORT=1636
@@ -18,8 +20,13 @@
RUN apt-get install -y wget unzip
RUN wget --quiet https://github.com/OpenIdentityPlatform/OpenDJ/releases/download/$VERSION/opendj-$VERSION.zip && unzip opendj-$VERSION.zip && rm -r opendj-$VERSION.zip
RUN wget --quiet \
  https://github.com/OpenIdentityPlatform/OpenDJ/releases/download/$VERSION/opendj-$VERSION.zip && \
  unzip opendj-$VERSION.zip && \
  rm -r opendj-$VERSION.zip
RUN /opt/opendj/setup --cli -p $PORT --ldapsPort $LDAPS_PORT --enableStartTLS --generateSelfSignedCertificate --baseDN "$BASE_DN" -h localhost --rootUserDN "$ROOT_USER_DN" --rootUserPassword $ROOT_PASSWORD --acceptLicense --no-prompt --doNotStart
RUN /opt/opendj/setup --cli -p $PORT --ldapsPort $LDAPS_PORT --enableStartTLS \
  --generateSelfSignedCertificate --baseDN "$BASE_DN" -h localhost --rootUserDN "$ROOT_USER_DN" \
  --rootUserPassword "$ROOT_PASSWORD" --acceptLicense --no-prompt --doNotStart $ADD_BASE_ENTRY
CMD ["/opt/opendj/bin/start-ds", "--nodetach"]