Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/blesswinsamuel/ldap-sql-adapter
An LDAP server that uses an already existing SQL database as backend
https://github.com/blesswinsamuel/ldap-sql-adapter
Last synced: 6 days ago
JSON representation
An LDAP server that uses an already existing SQL database as backend
- Host: GitHub
- URL: https://github.com/blesswinsamuel/ldap-sql-adapter
- Owner: blesswinsamuel
- Created: 2023-05-20T23:46:08.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-19T19:29:38.000Z (about 1 year ago)
- Last Synced: 2024-04-24T03:33:17.605Z (7 months ago)
- Language: Go
- Homepage:
- Size: 104 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# LDAP SQL Adapter
An LDAP server that uses an already existing SQL database as backend.
## Why?
I created this so that I could use my existing PostgreSQL database as a backend for authelia.
## Configuration
The configuration is done via command line flags or environment variables.
| Command Line Flag | Environment Variable | Default Value | Description |
| ------------------------------------------- | ----------------------------------------- | ------------------- | ------------------------------------------------------------------------------------------ |
| `--env` | `GO_ENV` | `development` | The environment in which the application is running. Decides which .env.{env} file to load |
| `--log-level` | `LOG_LEVEL` | `info` | The log level for the application |
| `--config` | `CONFIG` | N/A | The path to the configuration file |
| `--host` | `HOST` | `localhost` | The host on which the application should listen |
| `--http-port` | `HTTP_PORT` | `4181` | The port on which the application should listen for HTTP requests |
| `--ldap-port` | `LDAP_PORT` | `10389` | The port on which the application should listen for LDAP requests |
| `--bind-username` | `BIND_USERNAME` | `admin` | The username for the LDAP bind operation |
| `--bind-password` | `BIND_PASSWORD` | `admin` | The password for the LDAP bind operation |
| `--base-dn` | `BASE_DN` | `dc=example,dc=com` | The base DN for the LDAP search operation |
| `--database-url` | `DATABASE_URL` | N/A | The URL for the database connection |
| `--sql-get-user-password-by-username-query` | `SQL_GET_USER_PASSWORD_BY_USERNAME_QUERY` | `""` | The SQL query to retrieve a user's password by their username |
| `--sql-get-user-by-username-or-email-query` | `SQL_GET_USER_BY_USERNAME_OR_EMAIL_QUERY` | `""` | The SQL query to retrieve a user by their username or email |
| `--sql-get-user-groups-query` | `SQL_GET_USER_GROUPS_QUERY` | `""` | The SQL query to retrieve a user's groups |
| `--sql-update-password-query` | `SQL_UPDATE_PASSWORD_QUERY` | `""` | The SQL query to update a user's password |