BoxWorks 2020 - Box Platform Integration Best Practices
Architecture
UI
Login View
Content View
Set up and Run
- From the project root folder, create a Python 3.6+ virtual environment
$ virtualenv --python=python3 env
- Activate the virtual environment
$ source env/bin/activate
- Install the project dependencies
$ pip install -r requirements.txt
- Create a file at the project root folder called
box_jwt_keys.yml
and add your Box Platform JWT keys - Set the
FLASK_APP
environment variable referencing the flask app instance
$ export FLASK_APP=src/main:flask_app
- Bootstrap the Box environment
$ flask set_up_box_environment
- Add the 'In Review', 'Approved' and 'Rejected' folder IDs to the IDP constant on line 18 of
src/utils.py
- Run the development server
$ flask run
- From a browser, open
127.0.0.1:5000/content/login/
- Login with email
drodgers@box.com
passwordWelcome2020
Set up and Run with Docker
- From the project root folder, set the
FLASK_APP
environment variable referencing the flask app instance
$ export FLASK_APP=src/main:flask_app
- Bootstrap the Box environment
$ flask set_up_box_environment
- Add the 'In Review', 'Approved' and 'Rejected' folder IDs to the IDP constant in
src/utils.py
- Build and run the development Docker image
$ make dev
- From a browser, open
127.0.0.1:5000/content/login/
- Login with email
drodgers@box.com
passwordWelcome2020