With default Ubuntu/Debian installation of Jenkins, is there an easy way to change the deployment path? I'd like Jenkins to be available somewhere like http://localhost:8090/foobar
I'm looking for a way to configure it in /etc/default/jenkins
, similarly to setting the HTTP port:
# port for HTTP connector (default 8080; disable with -1)
HTTP_PORT=8090
/etc/default/jenkins
contains this bit which seems related, but I'm not sure how to use it:
# servlet context, important if you want to use apache proxying
PREFIX=/jenkins
Ah, looking at
/etc/default/jenkins
a bit more, this turned out very easy.The end of
/etc/default/jenkins
looks like this by default:So, you only need to set
PREFIX
to your liking, and editJENKINS_ARGS
to contain--prefix=$PREFIX
. SoJENKINS_ARGS
would be something like: