[GH-ISSUE #230] [Enhancement] Support custom UID:GID #80

Closed
opened 2026-02-27 08:15:07 +03:00 by kerem · 1 comment
Owner

Originally created by @martadinata666 on GitHub (Jul 9, 2022).
Original GitHub issue: https://github.com/lldap/lldap/issues/230

Add support for custom UID/GID.

  1. Use gosu
  2. Modified entrypoint
  3. Will use UID 1000 if not defined by user.

Sample of usage after supported

volumes:
  lldap_data:
    driver: local

services:
  lldap:
    image: nitnelave/lldap:stable
    ports:
      # For LDAP
      - "3890:3890"
      # For the web front-end
      - "17170:17170"
    volumes:
      - "lldap_data:/data"
      # Alternatively, you can mount a local folder
      # - "./lldap_data:/data"
    environment:
      - UID=2000 # desired UID
      - GID=3000 # desired GID
      - LLDAP_JWT_SECRET=REPLACE_WITH_RANDOM
      - LLDAP_LDAP_USER_PASS=REPLACE_WITH_PASSWORD
      - LLDAP_LDAP_BASE_DN=dc=example,dc=com

Any suggestions?

Originally created by @martadinata666 on GitHub (Jul 9, 2022). Original GitHub issue: https://github.com/lldap/lldap/issues/230 Add support for custom UID/GID. 1. Use gosu 2. Modified entrypoint 3. Will use UID 1000 if not defined by user. Sample of usage after supported ``` volumes: lldap_data: driver: local services: lldap: image: nitnelave/lldap:stable ports: # For LDAP - "3890:3890" # For the web front-end - "17170:17170" volumes: - "lldap_data:/data" # Alternatively, you can mount a local folder # - "./lldap_data:/data" environment: - UID=2000 # desired UID - GID=3000 # desired GID - LLDAP_JWT_SECRET=REPLACE_WITH_RANDOM - LLDAP_LDAP_USER_PASS=REPLACE_WITH_PASSWORD - LLDAP_LDAP_BASE_DN=dc=example,dc=com ``` Any suggestions?
kerem closed this issue 2026-02-27 08:15:07 +03:00
Author
Owner

@nitnelave commented on GitHub (Jul 11, 2022):

I think that sounds right. We might want to do in the entry point a chown of the DB (& private key?) to the given UID to solve most permission issues.
+1 to gosu, it looks like a good way to go.

<!-- gh-comment-id:1180531383 --> @nitnelave commented on GitHub (Jul 11, 2022): I think that sounds right. We might want to do in the entry point a chown of the DB (& private key?) to the given UID to solve most permission issues. +1 to `gosu`, it looks like a good way to go.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/lldap-lldap#80
No description provided.