Laurent Hinoul

“Always code as if the guy who ends up maintaining your code will be a violent psychopath who knows where you live.” - John F. Woods

How to change the root URL with Maven

An application with root name ‘myproject’ will have the following URL: ‘http://localhost:8080/myproject’.

I want change my URL to: ‘http://localhost:8080/mysite’.

How can I do that? With Maven.Add the code below in your pom.xml file:

It’s not more than that.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: