-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Andre Rosa
committed
Jun 14, 2018
0 parents
commit d40a7cb
Showing
5 changed files
with
322 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
### for all environments #### | ||
|
||
# versions | ||
nginx_version=i2b2tm.release-18.1 | ||
i2b2transmart_version=release-18.1-beta-5 | ||
db_version=oracle.12.2.0.1-ee-i2b2.1.7.09-tm.release-18.1-v.1.3-nhanes | ||
rserve_version=3.2.1-tm.release-18.1 | ||
solr_version=4.5.0-tm.release-18.1 | ||
i2b2_wildfly_version=1.7.09c-18.1-beta-hotfix | ||
irct_version=1.4.2 | ||
irctdb_version=mysql.5.7.22-irct.1.4.2-i2b2-nhanes | ||
fractalis_version=0.6.0 | ||
|
||
## labeling | ||
STACK_ENV=i2b2tm.release-18.1-beta | ||
STACK_NAME=quick-start | ||
|
||
COMPOSE_PROJECT_NAME=quickstart | ||
|
||
## container environment variables | ||
# loads these values into the container | ||
ENV_FILE=quick_start.env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
# i2b2/tranSMART release-18.1 Quick-Start | ||
|
||
_Database is pre-populated with the NHANES public dataset_ | ||
|
||
## Docker Host Hardware Requirements | ||
|
||
- 8GB RAM | ||
- 128GB Hard Drive | ||
- [Docker for Mac](https://docs.docker.com/docker-for-mac) and [Docker for Windows](https://docs.docker.com/docker-for-windows/) are not supported | ||
|
||
## Docker Network Requirements | ||
|
||
- HTTP (80) and HTTPS (443) ports (default) | ||
- Edit `.env` file to assign different ports | ||
|
||
```bash | ||
HTTP_PORT= | ||
HTTPS_PORT= | ||
``` | ||
|
||
## Compatible Docker Versions | ||
|
||
Docker: 17.06.2+ | ||
docker-compose: 1.14.0+ | ||
|
||
## Current Service Versions | ||
|
||
nginx: i2b2tm.release-18.1 | ||
i2b2transmart: release-18.1-beta-5 | ||
database: oracle.12.2.0.1-ee-i2b2.1.7.09-tm.release-18.1-v.1.3-nhanes | ||
rserve: 3.2.1-tm.release-18.1 | ||
solr: 4.5.0-tm.release-18.1 | ||
i2b2-wildfly: 1.7.09c-18.1-beta-hotfix | ||
fractalis: 0.4.2 | ||
irct: 1.4.2 | ||
irct database: mysql.5.7.22-irct.1.4.2-i2b2-nhanes | ||
|
||
## Deploy | ||
|
||
```bash | ||
$ cd deployments/i2b2transmart/release-18.1/quick-start | ||
|
||
# images take several minutes to download | ||
$ docker-compose pull | ||
|
||
# NOTE: if you are running docker-compose version 1.21.0+ | ||
# and the pull command fails, try: | ||
# $ docker-compose pull --no-parallel | ||
|
||
# deploy database *first deploy only* | ||
# database may hang here for a few minutes | ||
$ export COMPOSE_HTTP_TIMEOUT=300 | ||
$ docker-compose up -d db | ||
|
||
# verify database is up and running *first deploy only* | ||
$ docker-compose logs -f db | ||
# db_1 |######################### | ||
# db_1 | DATABASE IS READY TO USE! | ||
# db_1 | ######################### | ||
|
||
# deploy i2b2/tranSMART + fractalis | ||
$ docker-compose up -d | ||
``` | ||
|
||
## Test i2b2/tranSMART release-18.1 | ||
|
||
1. Browse to your docker machine IP | ||
2. i2b2/tranSMART, by default, uses self-signed certificates. If the browser complains about security, 'click OK' to allow for security exception. | ||
3. Default username and passwords are used, e.g. admin/admin | ||
|
||
## Troubleshoot | ||
|
||
Biggest point of failure is deploying the database for the first time. Due to its size and resource requirements, your Docker client may timeout during first deployment of the database. | ||
|
||
Docker is transferring the data from the Docker database image to the named volume `quickstart_i2b2transmart-db`. Notice, by running `docker system df` the total volume size increase: | ||
|
||
```bash | ||
TYPE TOTAL ACTIVE SIZE RECLAIMABLE | ||
Local Volumes 11 2 25.24GB 25.24GB (100%) | ||
``` | ||
|
||
If you run into a timeout error: | ||
|
||
```bash | ||
ERROR: for quickstart_db_1 HTTPSConnectionPool(host='xxxx', port=2376): Read timed out. (read timeout=60) | ||
``` | ||
|
||
Wait for data transfer to complete and the client to re-sync with the docker machine (~100s). Resume the deployment by running `docker-compose up -d db` again. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
SECRET_KEY = 'OVERWRITE ME IN PRODUCTION!!!' | ||
REDIS_HOST = 'redis' | ||
BROKER_URL = 'amqp://guest:guest@rabbitmq:5672//' | ||
CELERY_RESULT_BACKEND = 'redis://redis:6379' | ||
ETL_VERIFY_SSL_CERT = False |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,176 @@ | ||
version: '3.3' | ||
services: | ||
|
||
# nginx | ||
nginx: | ||
image: dbmi/nginx:${nginx_version} | ||
restart: always | ||
networks: | ||
- public | ||
# application stack exposed ports | ||
ports: | ||
- ${HTTP_PORT:-80}:80 | ||
- ${HTTPS_PORT:-443}:443 | ||
|
||
## i2b2transmart stack ## | ||
# transmart | ||
transmart: | ||
image: dbmi/i2b2transmart:${i2b2transmart_version} | ||
env_file: | ||
- ${ENV_FILE} | ||
restart: always | ||
depends_on: | ||
- nginx | ||
- solr | ||
- rserve | ||
- db | ||
volumes: | ||
- rserve-jobs:/tmp:rw | ||
networks: | ||
- public | ||
expose: | ||
- 8080 | ||
|
||
# i2b2transmart database | ||
db: | ||
image: dbmi/i2b2transmart-db:${db_version} | ||
networks: | ||
- public | ||
expose: | ||
- 1521 | ||
# i2b2transmart database exposed port | ||
ports: | ||
- ${DOCKER_DB_PORT:-1521}:1521 | ||
volumes: | ||
- i2b2transmart-data:/opt/oracle/oradata:rw | ||
|
||
# Rserve | ||
rserve: | ||
image: dbmi/rserve:${rserve_version} | ||
labels: | ||
- "edu.hms.harvard.dbmi.stack.name=${STACK_NAME}" | ||
- "edu.hms.harvard.dbmi.stack.env=${STACK_ENV}" | ||
restart: always | ||
expose: | ||
- 6311 | ||
volumes: | ||
- rserve-jobs:/tmp:rw | ||
networks: | ||
- public | ||
|
||
# solr | ||
solr: | ||
image: dbmi/solr:${solr_version} | ||
labels: | ||
- "edu.hms.harvard.dbmi.stack.name=${STACK_NAME}" | ||
- "edu.hms.harvard.dbmi.stack.env=${STACK_ENV}" | ||
env_file: | ||
- ${ENV_FILE} | ||
restart: always | ||
networks: | ||
- public | ||
expose: | ||
- 8983 | ||
|
||
## Fractalis Stack ## | ||
fractalis: | ||
image: sherzinger/fractalis:${fractalis_version} | ||
volumes: | ||
- ./config/fractalis/config.py:/config.py | ||
environment: | ||
- FRACTALIS_CONFIG=/config.py | ||
command: gunicorn -w 3 -b :5000 --log-file - --access-logfile - fractalis:app | ||
networks: | ||
- public | ||
expose: | ||
- 5000 | ||
depends_on: | ||
- irct | ||
- redis | ||
- rabbitmq | ||
- nginx | ||
- worker | ||
|
||
worker: | ||
image: sherzinger/fractalis:${fractalis_version} | ||
volumes: | ||
- ./config/fractalis/config.py:/config.py | ||
environment: | ||
- FRACTALIS_CONFIG=/config.py | ||
command: celery worker -A fractalis:celery -l info --autoscale 16,4 | ||
networks: | ||
- public | ||
depends_on: | ||
- redis | ||
- rabbitmq | ||
|
||
redis: | ||
image: redis:alpine | ||
command: > | ||
sh -c "redis-server | ||
&& redis-cli CONFIG SET maxmemory 4gb | ||
&& redis-cli CONFIG SET maxmemory-policy allkeys-lru" | ||
networks: | ||
- public | ||
|
||
rabbitmq: | ||
image: rabbitmq:alpine | ||
networks: | ||
- public | ||
|
||
## PIC-SURE API Stack ## | ||
# IRCT | ||
irct: | ||
image: dbmi/irct:${irct_version} | ||
depends_on: | ||
- irctdb | ||
- nginx | ||
- i2b2-wildfly | ||
env_file: | ||
- ${ENV_FILE} | ||
restart: always | ||
|
||
networks: | ||
- public | ||
expose: | ||
- 8080 | ||
|
||
# PIC-SURE i2b2-wildfly resource | ||
i2b2-wildfly: | ||
image: dbmi/i2b2-wildfly:${i2b2_wildfly_version} | ||
env_file: | ||
- ${ENV_FILE} | ||
restart: always | ||
networks: | ||
- public | ||
expose: | ||
- 9090 | ||
|
||
# IRCT DB | ||
irctdb: | ||
image: dbmi/irct-db:${irctdb_version} | ||
env_file: | ||
- ${ENV_FILE} | ||
restart: always | ||
command: --datadir=/mysql/data | ||
networks: | ||
- public | ||
expose: | ||
- 3306 | ||
# PIC-SURE database exposed port | ||
ports: | ||
- ${DOCKER_IRCT_DB_PORT:-3306}:3306 | ||
volumes: | ||
- irct-data:/mysql/data | ||
|
||
|
||
volumes: | ||
# PIC-SURE database | ||
irct-data: | ||
# i2b2/tranSMART database | ||
i2b2transmart-data: | ||
# shared volume for R jobs | ||
rserve-jobs: | ||
|
||
networks: | ||
public: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# i2b2transmart database | ||
DB_HOST=db | ||
DB_USER=BIOMART_USER | ||
BIOMART_USER=biomart_user | ||
DB_PORT=1521 | ||
DB_DB=ORCLPDB1 | ||
|
||
# fractalis | ||
FRACTALIS_ACTIVE=true | ||
FRACTALIS_NODE=/fractalis | ||
FRACTALIS_DATA_SOURCE=https://nginx | ||
FRACTALIS_RESOURCE_NAME=i2b2-wildfly-nhanes/Demo | ||
|
||
# i2b2-wildfly | ||
I2B2HIVE=demouser | ||
I2B2DEMODATA=demouser | ||
I2B2METADATA=demouser | ||
I2B2PM=demouser | ||
I2B2WORKDATA=demouser | ||
|
||
# required for JWT tokens between i2b2/tranSMART <-> PIC-SURE | ||
CLIENT_SECRET=dummysecret | ||
CLIENT_ID=dummyid | ||
|
||
# pic-sure | ||
IRCTMYSQLADDRESS=irctdb | ||
IRCT_DB_PORT=3306 | ||
IRCT_DB_CONNECTION_USER=root | ||
IRCTMYSQLPASS=password | ||
# use aud (audience) claim in JWT token | ||
IRCT_USER_FIELD=aud |