-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
58 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
## empty file used when override configs are not enabled |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# LDAP (OpenLDAP) | ||
|
||
LDAP (Lightweight Directory Access Protocol) is a protocol used to access and manage directory information such as user credentials. | ||
SciCat can use LDAP as third-party authentication provider. | ||
|
||
## Configuration options | ||
|
||
The OpenLDAP configuration is set by the [.env file](./config/.env). | ||
|
||
For an extensive list of available options see [here](https://hub.docker.com/r/bitnami/openldap). | ||
|
||
## Default configuration | ||
The default configuration [.env file](./config/.env) creates the `dc=facility` domain with the following user: | ||
|
||
| Username | Password | | ||
| --------- | -------- | | ||
| ldap-user | password | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
services: | ||
ldap: | ||
image: bitnami/openldap:2.6 | ||
volumes: | ||
- ./config/ldifs:/ldifs:ro | ||
env_file: | ||
- ./config/.env | ||
healthcheck: | ||
test: ldapwhoami -H ldap://ldap:389 -D 'cn=admin,dc=facility' -w 'admin' | ||
start_period: 5s | ||
interval: 10s | ||
timeout: 10s | ||
retries: 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
LDAP_ADMIN_USERNAME=admin | ||
LDAP_ADMIN_PASSWORD=admin | ||
LDAP_PORT_NUMBER=389 | ||
LDAP_ROOT=dc=facility |
11 changes: 11 additions & 0 deletions
11
services/backend/services/ldap/config/ldifs/01-bootstrap.ldif
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
dn: dc=facility | ||
objectClass: top | ||
objectClass: dcObject | ||
objectClass: organization | ||
o: My Organization | ||
dc: facility | ||
|
||
dn: ou=users,dc=facility | ||
objectClass: top | ||
objectClass: organizationalUnit | ||
ou: users |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
dn: uid=ldap-user,ou=users,dc=facility | ||
objectClass: top | ||
objectClass: person | ||
objectClass: organizationalPerson | ||
objectClass: inetOrgPerson | ||
uid: ldap-user | ||
cn: LDAP user | ||
displayName: ldap-user | ||
sn: LDAP | ||
givenName: User | ||
mail: ldap-user@facility.com | ||
userPassword: password |