I am developing Spring boot application with react client using gradle. I am new to all these technologies. Currently I am able to create war file which includes following folders:
- META-INF
- public (contains build of client part - index.html, index.js and other .js scripts)
- WEB-INF (contains compiled spring boot backend app)
Currently, after deploying war to tomcat, I am able to access client static content on http://localhost:8080/app-name/public/. Also I am able to access routes defined in spring controllers on http:// localhost:8080/app-name/route (these are just for testing purposes, I want this commands to be accessed only through REST calls from client).
Now, what I want is make that static client content available under route http://localhost:8080/app-name/xxx-yyy/public
I don't know what is right way to do this (actually, only way I know is create xxx-yyy subfolder on tomcat a put public folder inside it. I think this is bad approach). Other way would be somehow forward from spring controller but I am not able to do that.
It is possible that this is bad concept and I should make it other way. I would be glad for any suggestion.
Thank you