The OpenLDR provides a single storage location for the country-wide electronic data regarding laboratory requests and results. This allows laboratory systems managers to easily view relevant data on the entire country, different geographic levels or detailed data down to the lab and section. A major design goal of the OpenLDR is to accommodate data from laboratories which use disparate Laboratory Information Management Systems (LIMS). The OpenLDR defines a simple, easy to understand data model in order to simplify the merging of data, data analysis and the creation of report templates. The OpenLDR design specification can be implemented utilizing any relational database. While the design is “open” the data is not and is expected to be securely hosted by the aggregating organization (e.g. Ministry of Health).
- Drug susceptibility rates
- Viral Load suppression rates
- Early Infant Diagnosis results
- Laboratory workload by laboratory section and instrument
- Turn Around Times
- Demographic breakdowns for system use and test outcomes
- Geographic sample collection versus testing locations
- Database design
- Deployments
- Migrations
- Administration
- Query optimization
- Stored procedures
- Triggers
- Views
- Visualization/Reports
- APIs
Before you get started, you’ll need a couple of things:
Runtime Environment
- Node.js version 8.0 or higher
At Least One Database Engine
- Microsoft SQL
- MongoDB
- MySQL
- Postgres
- SQLite
.
├── api
│ └── projects
│ └── openldr
│ ├── certs
│ : └── ...
│ ├── src
│ │ ├── data
│ │ │ └── db
│ │ │ ├── mongodb
│ │ │ :
│ │ : ├── mssql
│ │ │ :
│ │ │ └── ...
│ │ ├── libraries
: : : └── ...
│ │ ├── plugins
│ │ │ └── plugin name
│ │ : ├── config.json
│ │ │ └── plugin.js
│ │ ├── routes
│ │ : └── ...
│ │ ├── views
│ │ : └── ...
│ │ ├── config.js
│ │ └── index.js
│ └── .env
├── doc
: └── ...
├── ui
│ ├── certs
│ : └── ...
│ ├── components
│ : └── ...
│ ├── lib
│ : └── ...
│ ├── public
│ │ ├── css
│ │ : └── ...
│ │ ├── fonts
: : : └── ...
│ │ ├── img
│ │ : └── ...
│ │ └── script
│ │ └── ...
│ ├── routes
│ : └── ...
│ ├── .env
│ ├── config.js
│ └── index.js
└── package.json
Before the tool can provide means to interact with database engines and users,
we need a good way to manage tool’s configuration, such as database connection information.
Using a .env
configuration file to set environment variables and validating those variables
in the config.js
file.
When using a source control system such as git, do not add the .env
file to source control. Each environment requires a custom .env file and may contain secrets that
should not be stored in a repository. The following example .env
configuration is the recommended variables expected
for the tool to work located api> projects > openldr > .env
.
PROXIES='openldr'
PROJECT_ID=openldr
PROJECT_NAME=Open Laboratory Data Repository
PROJECT_LOCATION=af-east-1
HTTP_PORT=5087
HTTPS_PORT=5443
ACCESS_TOKEN_SECRET=fake23hj123dd
ACCESS_TOKEN_LIFE=86400
REFRESH_TOKEN_SECRET=faketokensecretmmakhanjkajikhiwn2n
REFRESH_TOKEN_LIFE=86400
ACCESS_TOKEN_EMAIL=temp.user@fake.com
ACCESS_TOKEN_PASSWORD=faketoken123$$$
CRYPTO_ALGORITHM=aes-256-ctr
CRYPTO_KEY=fakekeympNWjRRIqCc7rdxs01lwHzfr3
CRYPTO_IV=fakeiv1mpNWjRRIqCc7rdxs01lwHzfr3
HTTPS_PFX=/certs/server.pfx
HTTPS_PASSPHRASE=fake_pass_phrase
DB_URI='Server=localhost,1433;User Id=fake_user;Password=fake_password;Encrypt=false;TrustServerCertificate=True;request timeout=180000;'
DB_DRIVER=mssql
DB_DATA=OpenLDRData
DB_DICT=OpenLDRDict
The ui also has its own .env
and here is an example configuration with recommended variables.
It's located ui> .env
.
HTTP_PORT=7087
HTTPS_PORT=7443
ACCESS_TOKEN_SECRET=fake23hj123dd
ACCESS_TOKEN_LIFE=86400
REFRESH_TOKEN_SECRET=faketokensecretmmakhanjkajikhiwn2n
REFRESH_TOKEN_LIFE=86400
ACCESS_TOKEN_EMAIL=temp.user@fake.com
ACCESS_TOKEN_PASSWORD=faketoken123$$$
CRYPTO_ALGORITHM=aes-256-ctr
CRYPTO_KEY=fakekeympNWjRRIqCc7rdxs01lwHzfr3
CRYPTO_IV=fakeiv1mpNWjRRIqCc7rdxs01lwHzfr3
HTTPS_PFX=/certs/server.pfx
HTTPS_PASSPHRASE=fake_pass_phrase
Download the source from here or git clone like
git clone https://github.com/APHL-Global-Health/OpenLDR.git
Navigate to OpenLDR
directory and download the dependencies required using npm like
npm i
There are several ways of starting the tool, the prefered methods are
npm run start:all
or npm run start:openldr
If you used the git clone method, you can fetch updates like
git pull origin main
For full documentation about OpenLDR, visit openldr.org
- Community Forum. Best for: help with building, discussion about best practices.
- GitHub Issues. Best for: bugs and errors you encounter.
- Public Alpha: Testing with a closed set of parties
- Public Beta: Stable enough for most non-enterprise use-cases
- Public: Production-ready
We are currently in Public Alpha. Watch "releases" of this repo to get notified of major updates.
- Supabase : an open source Firebase alternative