From 8a749e89dac1bea25de362eec963ceda46a3c993 Mon Sep 17 00:00:00 2001 From: Chris Gorgolewski Date: Fri, 2 Jun 2017 15:10:45 -0700 Subject: [PATCH] versioning and other stuff --- dockereve-master/eve-app/app.py | 2 +- dockereve-master/eve-app/settings.py | 3 +++ dockereve-master/nginx/sites-enabled/eve_project | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/dockereve-master/eve-app/app.py b/dockereve-master/eve-app/app.py index e482917..81c4f22 100644 --- a/dockereve-master/eve-app/app.py +++ b/dockereve-master/eve-app/app.py @@ -20,7 +20,7 @@ def check_auth(self, token, allowed_roles, resource, method): # required. See http://swagger.io/specification/#infoObject for details. app.config['SWAGGER_INFO'] = { 'title': 'MRIQC Web API', - 'version': '0.1', + 'version': 'v1', 'description': 'MRI Quality Control Metrics Repository', } diff --git a/dockereve-master/eve-app/settings.py b/dockereve-master/eve-app/settings.py index 5bbc0fb..8664c56 100644 --- a/dockereve-master/eve-app/settings.py +++ b/dockereve-master/eve-app/settings.py @@ -549,6 +549,9 @@ settings = { + 'URL_PREFIX': 'api', + 'API_VERSION': 'v1', + 'ALLOWED_FILTERS': ['*'], 'MONGO_HOST': os.environ.get('MONGODB_HOST', ''), 'MONGO_PORT': os.environ.get('MONGODB_PORT', ''), 'MONGO_DBNAME': 'mriqc_api', diff --git a/dockereve-master/nginx/sites-enabled/eve_project b/dockereve-master/nginx/sites-enabled/eve_project index 4260e20..258e4d2 100644 --- a/dockereve-master/nginx/sites-enabled/eve_project +++ b/dockereve-master/nginx/sites-enabled/eve_project @@ -11,7 +11,7 @@ server { proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; } - location /docs/ { + location = / { proxy_pass http://swagger_ui:8080/; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr;