So I wanted to setup Jenkins external monitoring on a web server I have on a Centos VM, and I found a combination of these three blog posts worked!
Firstly, run the following commands :
wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
rpm --import http://pkg.jenkins-ci.org/redhat/jenkins-ci.org.key
yum -y install jenkins
… or download the RPM at http://pkg.jenkins-ci.org/redhat/ and run “rpm -Uhv jenkinx*.rpm”
cd /usr/lib/jenkins
unzip /usr/lib/jenkins/jenkins.war
\* Create an environment variable by
$export JENKINS\_HOME=http://jenkins\_host:8080 , replacing "jenkins\_host" with the server running Jenkins
java -jar /usr/lib/jenkins/WEB-INF/lib/jenkins-core-\*.jar “New Job” /path\_to/myreport.sh 2>&1 > /dev/null
And you can put that command in a cron job too!