Skip to content

Commit

Permalink
Merge branch 'master' into lazy_load_builder
Browse files Browse the repository at this point in the history
  • Loading branch information
adelavega committed May 4, 2021
2 parents 304334a + e549bef commit 5bfecf8
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 17 deletions.
7 changes: 0 additions & 7 deletions neuroscout/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,3 @@ def confirm(token):
return render_template(
'confirm.html', confirmed=confirmed, expired=expired, invalid=invalid,
name=name, action_url=url_for('index', _external=True))


@app.route('/', defaults={'path': ''})
@app.route('/<path:path>')
def index(path):
''' Serve index '''
return send_file("frontend/build/index.html")
4 changes: 2 additions & 2 deletions neuroscout/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ nltk==3.2.2
numpy==1.18.0
olefile==0.44
packaging==16.8
pandas==0.23
pandas==1.1.5
passlib==1.7.1
patsy
Pillow==7.1.0
Expand All @@ -56,7 +56,7 @@ pyld==0.7.3
pyparsing==2.2.0
pytest>4.6
joblib
python-dateutil==2.6.0
python-dateutil
python-magic==0.4.13
pytz==2017.2
oauth2client==4.1.3
Expand Down
20 changes: 12 additions & 8 deletions nginx/nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -44,18 +44,17 @@ http {
gzip_proxied any;
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript application/javascript;


server {
server_name _;
root /neuroscout/neuroscout/frontend/build;

location /static/ {
}

location /analyses {
location /static {
}
location /analyses {
alias /file-data/analyses;
}

Expand All @@ -78,8 +77,13 @@ http {
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}

location / {
proxy_pass http://neuroscout:8000;
location = / {
root /neuroscout/neuroscout/frontend/build;
try_files /index.html =404;
}

location ^~ / {
proxy_pass http://neuroscout:8000/;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
Expand Down

0 comments on commit 5bfecf8

Please sign in to comment.