I think I’ve already tried all the possible combinations, but I cannot make the nexus work well with custom contextpath
nexus-context-path=/nexus
#nexus-webapp=${bundleBasedir}/nexus
nexus-webapp=/nexus
nexus-webapp-context-path=/nexus
I can make static web resources load now, but I have not managed to get the
/service/extdirect
calls obey context-path. As a result I cannot proxy nexus through nginx based on URL.
Could you please help me out?
It feels like frontend ir not prepending the context-path prefix when making /service/extdirect calls behind proxy.
I had to add a separate non-prefixed mapping in nginx config to route /service/extdirect requests to backend. This configuration works. However if I remove the 2nd proxy forwarder I’m again getting errors in web-gui:
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Forwarded-Port $server_port;
location ~ ^/nexus/?(.*)$ {
proxy_pass http://nexus/nexus/$1$is_args$args;
}
location ~ ^/service/extdirect/?(.*)$ {
proxy_pass http://nexus/nexus/service/extdirect/$1$is_args$args;
}
EDIT: nexus web-gui works as expected when interacting w/o a proxy : http://nexus.netikras.com:8081/nexus/ . Same configuration.