Skip to content

Configuring API Umbrella with LDAP #278

@pradeeban

Description

@pradeeban

I am trying to configure API Umbrella with OpenLDAP, both running in docker containers. Unfortunately when ldap is enabled in the configuration file, https://lion.bmi.emory.edu/admin/ is throwing a gateway timeout. This might be something to do with the OmniAuth LDAP configurations. Please let me know whether I missed something. I see some procedures in https://github.com/intridea/omniauth-ldap which I did not follow. Do I have to follow them too? The steps that I followed are detailed below.

Add to /etc/hosts:
127.0.0.1 ldap.my-company.com

Make the configuration file:
$ mkdir config && touch config/api-umbrella.yml

web:
admin:
initial_superusers:
- [email protected]
auth_strategies:
enabled:
- github
- google
- persona
- ldap
github:
client_id: xxxxxxxxxxxxx
client_secret: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
google:
client_id: yyyyyy-yyyy.apps.googleusercontent.com
client_secret: yyyyyyyyyyyyyyyyyyyyyyyyyyyyyyyy
ldap:
options:
host: lion.bmi.emory.edu
port: 389
base: dc=example, dc=org

Follow the wiki on configuring github and google authentication.
http://api-umbrella.readthedocs.io/en/latest/getting-started.html

(Everything works fine without LDAP enabled in the configuration. So the issue is specific to LDAP configuration).

Run the OpenLDAP Docker container:
sudo docker run --hostname lion.bmi.emory.edu -p 389:389 -p 636:636 --name my-openldap-container --detach osixia/openldap:1.1.5

Run the API Umbrella Docker container:
sudo docker run -d --name=api-umbrella -p 80:80 -p 443:443 --link my-openldap-container:ldap -v $PWD/config:/etc/api-umbrella
-v /var/log/api-umbrella/nginx:/var/log/api-umbrella/nginx
-v /var/log/api-umbrella/web-puma/current:/var/log/api-umbrella/web-puma/current
-v /var/log/api-umbrella/trafficserver/access.blog:/var/log/api-umbrella/trafficserver/access.blog
nrel/api-umbrella

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions