server.py 715 B

123456789101112131415161718192021222324
  1. import logging
  2. from logging.config import dictConfig
  3. # Environment must be set before importing the app factory function.
  4. import lakesuperior.env_setup
  5. from lakesuperior.config_parser import config
  6. from lakesuperior.globals import AppGlobals
  7. from lakesuperior.env import env
  8. from lakesuperior.app import create_app
  9. dictConfig(env.config['logging'])
  10. logger = logging.getLogger(__name__)
  11. logger.info('Graph store location: {}'.format(
  12. env.config['application']['store']['ldp_rs']['location']))
  13. logger.info('Binary store location: {}'.format(
  14. env.config['application']['store']['ldp_nr']['path']))
  15. fcrepo = create_app(env.config['application'])
  16. if __name__ == "__main__":
  17. fcrepo.run(host='0.0.0.0')