Lectern
Lectern and Lyric form Overture's structured, dictionary-driven tabular data submission system. Lectern manages the dictionaries that define your tabular data, and Lyric validates and stores tabular submissions against those dictionaries.
Lyric depends on Lectern, so set up Lectern first. After this page, continue to Lyric.
Setting up the Lectern database
Lectern stores its dictionaries, versions, and metadata in MongoDB.
-
Run MongoDB: Use the following command to pull and run the MongoDB docker container
docker run -d --name lectern-mongo \-e MONGODB_USERNAME=admin \-e MONGODB_PASSWORD=password \-e MONGODB_DATABASE=lectern \-e MONGODB_ROOT_PASSWORD=password123 \-p 27017:27017 \bitnami/mongodb:4.0For more details, click here
- This runs a MongoDB instance named
lectern-mongowith an application useradmin(passwordpassword) scoped to thelecterndatabase. - Lectern connects to this database using the
MONGO_*variables set in the next step.
- This runs a MongoDB instance named
Running Lectern
-
Run Lectern: Use the following command to pull and run the Lectern docker container
docker run -d --name lectern \-e PORT=3000 \-e MONGO_HOST=lectern-mongo \-e MONGO_PORT=27017 \-e MONGO_DB=lectern \-e MONGO_USER=admin \-e MONGO_PASS=password \-e AUTH_ENABLED=false \-p 3000:3000 \ghcr.io/overture-stack/lectern:latestClick here for a detailed breakdown
Lectern Variables
PORTis the port Lectern listens on (default3000).MONGO_HOST,MONGO_PORT,MONGO_DB,MONGO_USER, andMONGO_PASSpoint Lectern at the MongoDB instance from the previous step. Alternatively, setMONGO_URLto a full connection string, which overrides these discrete variables.AUTH_ENABLEDtoggles JWT-based authorization. It is set tofalsehere for a simpler local deployment; enable it and setEGO_APIandSCOPEto secure Lectern.
infoOnce running, the Lectern API and its Swagger UI are available at
http://localhost:3000/api-docs.