I have Jenkins sitting behind Nginx, with Nginx taking care of authentication, but Jenkins is still listening on port 8080 externally, so by accessing the box on port 8080 people can bypass Nginx.
How can I tell it to stop listening for remote connections and just accept connections locally?
It looks like it might be something to do with this ajp13ListenAddress param, but I can't figure out how to set that in the init.d script installed with Jenkins.
Thanks loads for any help!
Ludo.
(Looks like there's no Jenkins tag yet and I can't create it as I don't have rep)
Debian
If you installed Jenkins from the Debian package, you can modify
/etc/default/jenkins
and add the following line somewhere:and then add
--httpListenAddress=$HTTP_HOST
to the JENKINS_ARGS so that it reads something like:Ubuntu
If you installed Jenkins from the Ubuntu Oneiric (11.10) package, edit
/etc/init/jenkins.conf
and add--httpListenAddress=127.0.0.1
to theJENKINS_ARGS
line, so that it reads like:RedHat/CentOS/Amazon Linux
If you installed Jenkins using YUM repository, modify
/etc/sysconfig/jenkins
and editJENKINS_LISTEN_ADDRESS
toJENKINS_LISTEN_ADDRESS=127.0.0.1