Installation
INFO
This section will provide installation instructions for installing a PHT Station.
It assumes that the station has been registered in the UI.
For instructions on how to register the station see the instructions here.
Requirements
- Docker and docker-compose need to be installed.
- For the default installation to work the ports
8080
and5432
need to be available on localhost.
Setup
Warning
If the station is set up on windows, the changes described here must be made, before executing the following steps.
Clone the repository:
git clone https://github.com/PHT-Medic/station.git
Navigate into the cloned project
cd station
and edit the.env
file with your local configuration and the credentials you received after the Public key registration.
Note: The.env.tmpl
file is a template file that can be used to generate a.env
file with the correct environment keys.
Attribute | Explanation |
---|---|
STATION_ID | Chosen identifier of the station (match central UI configuration). You can find it as namespace |
STATION_PRIVATE_KEY_PATH | Path to the private key on the local filesystem that should be mounted as a volume |
PRIVATE_KEY_PASSWORD | If the private key is encrypted with a password, this password can be set using this variable |
AIRFLOW_USER | Admin user to be created for the airflow instance |
AIRFLOW_PW | Password for the airflow admin user |
HARBOR_URL | Url of the central harbor instance |
HARBOR_USER | Username to authenticate against harbor |
HARBOR_PW | Password to authenticate against harbor |
STATION_DATA_DIR | Absolute path of the directory where the station stores the input data for trains. This path is also used by the FHIR client to store the query results before passing them to the trains |
FHIR_ADDRESS (optional) | Address of the default FHIR server connected to the station (this can also be configured per train) |
FHIR_USER (optional) | Username to authenticate against the FHIR server using Basic Auth |
FHIR_PW (optional) | Password for FHIR server Basic Auth |
FHIR_TOKEN (optional) | Token to authenticate against the FHIR server using Bearer Token |
CLIENT_ID (optional) | Identifier of client with permission to acces the FHIR server |
CLIENT_SECRET (optional) | Secret of above client to authenticate against the provider |
OIDC_PROVIDER_URL (optional) | Token url of Open ID connect provider (e.g. keycloak, that is configured for the FHIR server) |
FHIR_SERVER_TYPE (optional) | Type of FHIR server (PHT FHIR client supports IBM, Hapi and Blaze FHIR servers) |
- Create a volume for the station:
docker volume create pg_station
- Build the images by running:
docker-compose build
Execution
- Run
docker-compose up -d
- Check that the logs do not contain any startup errors with
docker-compose logs -f
- Go to
http://localhost:8080
nd check whether you can see the web interface of Apache Airflow - Login to the airflow web interface with the previously set user credentials