Commit aaf5ad6f authored by robert.vincze's avatar robert.vincze

TVB-2593: Made Flask run in development mode

parent 03718e9e
FLASK_ENV=development
\ No newline at end of file
......@@ -30,7 +30,6 @@
import os
import sys
from flask import Flask
from tvb.basic.logger.builder import get_logger
from tvb.basic.profile import TvbProfile
......@@ -47,6 +46,8 @@ from tvb.interfaces.rest.server.resources.project.project_resource import GetOpe
from tvb.interfaces.rest.server.resources.simulator.simulation_resource import FireSimulationResource
from tvb.interfaces.rest.server.resources.user.user_resource import GetUsersResource, GetProjectsListResource
from tvb.interfaces.rest.server.rest_api import RestApi
from dotenv import load_dotenv
TvbProfile.set_profile(TvbProfile.COMMAND_PROFILE)
......@@ -55,6 +56,9 @@ LOGGER.info("TVB application will be running using encoding: " + sys.getdefaulte
FLASK_PORT = 9090
dotenv_path = os.path.join(os.path.dirname(__file__), '.env') # Path to .env file
load_dotenv(dotenv_path)
def initialize_tvb(arguments):
if not os.path.exists(TvbProfile.current.TVB_STORAGE):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment