Documentation
Getting startedInstallationLoading data with AirflowQuerying the databaseFinding tables in pgAdminHow SageRx worksData dictionary
Show me the dataData sourcesSource dataStaging dataIntermediate dataMartsUse cases
Use casesExample queriesInstallation
A guide to installing SageRx locally.
Install locally
GitHub repo
Prerequisites
- Install Docker.
- Windows users will also install WSL 2 (a Linux subsystem that runs on Windows) as part of this process.
Installation
- Clone the repo.
git clone https://github.com/coderxio/sagerx.git
- Add a
.env
file at the root of the repo.
cd sagerx
touch .env
- Add ENV vars to the
.env
file.
AIRFLOW_UID=<uid>
UMLS_API=<umls_api_key>
AIRFLOW_UID=<uid>
- UID can be found by runningid -u
on linux systems, typically the first user on the system is1000
or1001
.- Windows users following the Docker Desktop install guide should have WSL 2 installed. You can open up command line, type
wsl
and then within WSL 2, you can enterid -u
to see your UID. UMLS_API=<umls_api_key>
- (optional) if you want to use RxNorm, you need an API key from UMLS.
- Run
docker-compose up airflow-init
and wait until exit code 0.
Make sure docker is installed. See prerequisites section above.
docker-compose up airflow-init
- Run
docker-compose up
.
docker-compose up
NOTE: if you have an M1 Mac export DOCKER_DEFAULT_PLATFORM=linux/amd64, and re-build your images
← Previous