Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
executable file 29 lines (20 sloc) 590 Bytes
#!/bin/bash -ex
URL="http://pkg.jenkins-ci.org/debian-stable"
NAME="jenkins"
mkdir -p /usr/share/keyrings
wget -q -O - $URL/jenkins-ci.org.key | gpg --dearmor > /usr/share/keyrings/jenkins.gpg
cat >/etc/apt/sources.list.d/$NAME.list<<EOF
deb [signed-by=/usr/share/keyrings/jenkins.gpg] $URL binary/
EOF
cat >/etc/apt/preferences.d/$NAME<<EOF
Package: *
Pin: release o=jenkins-ci.org
Pin-Priority: 100
Package: $NAME
Pin: release o=jenkins-ci.org
Pin-Priority: 500
EOF
apt-get -y update
DEBIAN_FRONTEND=noninteractive apt-get --assume-yes install $NAME
sleep 5
service jenkins stop
You can’t perform that action at this time.