Deploy SSR application on XAMPP webserver
-
Re: SPA-SSR Deployment with Apache
Found this related topic that has pretty much the same issue as I do. I am writing a SSR application and I want it to run under http://localhost/app/, and I’ve created an Reverse Proxy that works successfully but all the assets are added with absolute paths http://localhost/js/example.js which is wrong because it should be http://localhost/app/js/example.js.
I’ve tried with publicPath under the build property to set it to ‘/app/’ but nothing seems to change.
Also please note that:
pwa -> false
vueRouterMode -> tried with both history | hash -
Basically the issue is that link have absolute paths ‘/’ instead of relative
-
Hi,
You can’t use SSR with a custom public path, even if you wrap it with some reverse proxy. It’s just not how SSR works. Use a subdomain (when deploying) instead.
Also, there’s the quasar.conf.js > build > forceDevPublicPath (https://quasar.dev/quasar-cli/quasar-conf-js#Property%3A-build) – but only for dev mode AND if you REALLY know what you are doing (otherwise you can break your whole app).