Running the service outside of a docker container

It is recommended that the service be deployed as a docker container, following the instructions here. However you can run it outside of docker if you need to.

  1. Build and install nlp-insights to a virtual environment
    ./gradlew install

  2. Switch to the virtual env where nlp-insights is installed
    source ./build/venv/bin/activate

  3. Set the FLASK_APP environment variable to the installed package
    export FLASK_APP=nlp_insights.app

  4. Start the service (5000 is the default port, however this value can be changed to suit your needs)
    python -m flask run --port=5000