Closed mtissington closed 6 months ago
Hello @mtissington,
ldap-ui
consists of the TypeScript frontend and the Python backend. A local install is possible but unfortunately the README does not fully spell it out.
For the frontend, npm run build
assembles everything in the dist
directory. Obviously, npm
should be available on the machine / container where this happens. It can be the web server, but I always do it on a development box and then copy the dist
folder to the remote box. The result can then be served directly via the backend (during development), or statically by any other web server (remotely).
The backend translates parts of the LDAP protocol as a stateless ReST API for use by the frontend. You can run it locally anywhere, but always as a separate process. There is an example systemd
unit in etc/ldap-ui.service
. Most people would prefer a virtual environment such that the dependencies from requirements.txt
do not clash with other Python processes, but YMMV.
The best reference for local build rules is the provided Makefile
. When the backend is run with systemd
or make run
, the API is available on localhost
, port 5000, which is fine for a dev box, but not reachable from outside on a remote box.
So, to have it served remotely via nginx
, let's assume that everything should appear under the HTTP path /ldap
:
dist
can be statically served under /ldap
by nginx
./ldap/api
should be proxied to http://localhost:5000/api
Hope this clarifies it.
Hello and thanks for the detailed answer ... thinking about docker (which sounds easier) .. I have my ldap server using a socket, ldapi:/// I'm totally new with docker, can I configure the docker image to use host socket for ldap?
You can probably mount the socket (/run/slapd/ldapi
on Debian) into the ldap-ui
container, access rights should be no problem as it is world-writable by default. I have not tried it myself, but there are plenty of socket-binding examples for Docker on the internet.
No further activity → closed
I'm a little confused how this runs. Can I install and run it on nginx and if so how? Does it need to be in a virtual environment?
Thanks