Created
September 17, 2014 19:48
-
-
Save lukespragg/aefca8bc59b63f2d13e1 to your computer and use it in GitHub Desktop.
Jenkins updater script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo Checking current Jenkins version... | |
# Read X-Jenkins HTTP header info | |
echo Checking for latest Jenkins release... | |
# http://updates.jenkins-ci.org/latestCore.txt | |
# echo Checking for jobs in queue before updating... | |
# http://localhost:8080/jenkins/queue/api/xml or http://localhost:8080/jenkins/queue/api/json | |
# <queue></queue> | |
echo Downloading latest jenkins.war... | |
wget -v --no-check-certificate -m -nd -O "/var/lib/tomcat6/webapps/jenkins.war" http://updates.jenkins-ci.org/latest/jenkins.war | |
# or just do apt-get update ?? | |
# Just do this instead of cheating queue for jobs? | |
# http://localhost:8080/jenkins/safeRestart |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment