static file url rewrite
Valentin V. Bartenev
vbart at nginx.com
Wed Dec 4 18:57:32 UTC 2019
On Wednesday 04 December 2019 17:42:39 Wee Sritippho wrote:
> Hi all,
>
> I'm using nginx unit to serve my Vue.js app and trying to redirect every
> uri (except '/api/*') to the app.
>
> In nginx, I can do something like this:
>
> location / {
> try_files $uri $uri/ /index.html;
> }
>
> How can I do the same using nginx unit?
[..]
Unfortunately, right now there's no way in Unit to make routing decisions based
on presence of file system objects. Although this feature is planned.
Currently you can try to specify all static content, that you have in your
application. See here for example:
- https://unit.nginx.org/configuration/#id1
wbr, Valentin V. Bartenev
More information about the unit
mailing list