diff --git a/deploy/nginx.conf b/deploy/nginx.conf index 90d74e49..b2c1bdb2 100644 --- a/deploy/nginx.conf +++ b/deploy/nginx.conf @@ -75,4 +75,10 @@ server { location / { proxy_pass http://127.0.0.1:8081; } + + # Serve JS files from the output directory. We use a regular expression + # match to ensure that we only serve JS files. + location ~ ^/output/(.+\.js)$ { + alias /var/www/trypurescript/staging/.psci_modules/node_modules/$1; + } }