Home

Issue: 1352

Javascript doesn't work when put behind nginx with subdirectory

[issue link]

Hello.

So basically, I have a nuxt application that is put behind nginx. The problem is that it is accessable through subdirectory (http://127.0.0.1/admin/ in my case). However, I see nuxt loading these scripts:

  • /_nuxt/manifest.612c946d31d19ad5d679.js
  • /_nuxt/vendor.bundle.68b421f11efb0ddd8251.js
  • /_nuxt/app.js

They do not exist, because whole application is accessable only through subdirectory.

My nginx configuration looks like this:

location ~* /admin {
    proxy_pass http://127.0.0.1:3000;
}

Is there a solution for this right now or it has to be implemented?
If it has to be implemented, please give me some hints and I may do it myself 😃

Thanks!

This question is available on Nuxt.js community (#c1199)