Two "bin" in all URLs in the application menu

I have set up a new Xwiki and in that process I imported an old one (created by a predecessor as a stand-alone Docker image and who has since left the company). I have also changed the root context for the tomcat application (and added SSL) so my wiki now responds to

I have added a structure of pages and that works just fine – the Home link in the Navigation menu, for instance, points to and that is well. What is not well is what I see under the Applications heading in the left column. Take the Dashboard icon, for instance, it expands to and that double “bin” thing is really a bother.

I tried to remove the icons from Global Administration: Applications Panel and then add them again but the erronous URL seems to be intrinsic to the icon and not something that is added dynamically when I add the icon. Furthermore is the link “More applications” also screwed up; it directs to which, of course, does not work.

I just discovered a related issue and that is that there are no images on user names, only a broken image icon. When I try to load the image I get the URL… which, of course, does not work. Same thing applies to links to pages in notifications – they also contain a double “bin”.

Any idea how I can fix this and get rid of the superfluous “bin” in those URLs? I tried to search for them in an SQL dump of the database in the vain hope that I could patch the database but that did not come up with any hits.

So this is all due to the change of root context I did. It turns out that if I change the root context according to ths instructions at XWiki on Ubuntu 16.04 LTS with Nginx Reverse Proxy –, the problems I described appears. Bother.

Lesson learned: do not fiddle with the context path in /etc/tomcat9/Catalina/localhost/xwiki.xml