Merge pull request #360 from jenkinsci/2.19.1
Upgrade to the new LTS baseline: 2.19.1
diff --git a/install-plugins.sh b/install-plugins.sh
index db96b4b..17145c0 100755
--- a/install-plugins.sh
+++ b/install-plugins.sh
@@ -67,7 +67,7 @@
url="$JENKINS_UC_DOWNLOAD/plugins/$plugin/$version/${plugin}.hpi"
echo "Downloading plugin: $plugin from $url"
- curl --connect-timeout 5 --retry 5 --retry-delay 0 --retry-max-time 60 -s -f -L "$url" -o "$jpi"
+ curl --connect-timeout ${CURL_CONNECTION_TIMEOUT:-20} --retry ${CURL_RETRY:-5} --retry-delay ${CURL_RETRY_DELAY:-0} --retry-max-time ${CURL_RETRY_MAX_TIME:-60} -s -f -L "$url" -o "$jpi"
return $?
}
diff --git a/tests/install-plugins.bats b/tests/install-plugins.bats
index ffde661..b035dac 100644
--- a/tests/install-plugins.bats
+++ b/tests/install-plugins.bats
@@ -98,7 +98,7 @@
local work; work="$BATS_TEST_DIRNAME/upgrade-plugins/work"
mkdir -p $work
# Image contains maven-plugin 2.7.1 and ant-plugin 1.3
- run bash -c "docker run -u $UID -v $work:/var/jenkins_home --rm $SUT_IMAGE-install-plugins curl --connect-timeout 5 --retry 5 --retry-delay 0 --retry-max-time 60 -s -f -L https://updates.jenkins.io/download/plugins/maven-plugin/2.12.1/maven-plugin.hpi -o /var/jenkins_home/plugins/maven-plugin.jpi"
+ run bash -c "docker run -u $UID -v $work:/var/jenkins_home --rm $SUT_IMAGE-install-plugins curl --connect-timeout 20 --retry 5 --retry-delay 0 --retry-max-time 60 -s -f -L https://updates.jenkins.io/download/plugins/maven-plugin/2.12.1/maven-plugin.hpi -o /var/jenkins_home/plugins/maven-plugin.jpi"
assert_success
run bash -c "unzip -p $work/plugins/maven-plugin.jpi META-INF/MANIFEST.MF | tr -d '\r'"
assert_line 'Plugin-Version: 2.12.1'
diff --git a/weekly.sh b/weekly.sh
index 347d9d9..da3efff 100755
--- a/weekly.sh
+++ b/weekly.sh
@@ -3,7 +3,7 @@
set -e
set -x
-JENKINS_VERSION=$(curl -sq https://api.github.com/repos/jenkinsci/jenkins/tags | grep '"name":' | grep -E -o '\d+(\.\d+)+' | uniq | sort --version-sort | tail -1)
+JENKINS_VERSION=$(curl -sq https://api.github.com/repos/jenkinsci/jenkins/tags | grep '"name":' | egrep -o '[0-9]+(\.[0-9]+)+' | sort --version-sort | uniq | tail -1)
echo "$JENKINS_VERSION"
JENKINS_SHA=$(curl "http://repo.jenkins-ci.org/simple/releases/org/jenkins-ci/main/jenkins-war/${JENKINS_VERSION}/jenkins-war-${JENKINS_VERSION}.war.sha1")