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
for (plugin in ["ant", | |
"artifactdeployer", | |
"build-failure-analyzer", | |
"build-name-setter", | |
"build-pipeline-plugin", | |
"build-timeout", | |
"claim", | |
"clone-workspace-scm", | |
"cobertura", | |
"collapsing-console-sections", |
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
import jenkins.* | |
import jenkins.model.* | |
import hudson.* | |
import hudson.model.* | |
def DRY_RUN = false | |
def DIRS_FILTER = ['.hg', 'production','logs','apache', 'projects', 'qlickview'] | |
def JOBS_WS_ROOT = 'path-to-your-workspaces-root-dir' | |
def JOBS_IRRELEVANT_SYMBOLS = "[_,-]|\\s" | |
def allJobs = Jenkins.instance.items.findAll { it instanceof hudson.model.Job }.collect { it.name }; |
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
# download and install | |
antversion=1.7.1 | |
wget http://archive.apache.org/dist/ant/binaries/apache-ant-${antversion}-bin.tar.gz | |
sudo tar xvfvz apache-ant-${antversion}-bin.tar.gz -C /opt | |
sudo ln -sfn /opt/apache-ant-${antversion} /opt/ant | |
sudo sh -c 'echo ANT_HOME=/opt/ant >> /etc/environment' | |
sudo ln -sfn /opt/ant/bin/ant /usr/bin/ant | |
# check installation | |
ant -version |
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
# architecture # | |
lscpu | |
# release # | |
# RHEL, CentOS | |
cat /etc/redhat-release | |
# Ubuntu | |
cat /etc/issue | |
lsb_release -a |
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/bash | |
JDK_URL=http://download.oracle.com/otn-pub/java/jdk/8u74-b02/jdk-8u74-linux-x64.tar.gz | |
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" $JDK_URL | |
sudo mkdir -p /opt/jdk | |
sudo tar -zxf jdk-8u74-linux-x64.tar.gz -C /opt/jdk | |
sudo update-alternatives --install /usr/bin/java java /opt/jdk/jdk1.8.0_74/bin/java 100 | |
rm jdk-8u74-linux-x64.tar.gz |
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/bash | |
# jdk | |
sudo su root | |
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u73-b02/jdk-8u73-linux-x64.tar.gz | |
tar -zxf jdk-8u73-linux-x64.tar.gz -C /opt | |
update-alternatives --install /usr/bin/java java /opt/jdk1.8.0_73/bin/java 100 | |
echo 'export JAVA_HOME=/opt/jdk1.8.0_73' >> /home/ubuntu/.bash_profile | |
rm jdk-8u73-linux-x64.tar.gz |
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
# installs to /opt/gradle | |
# existing versions are not overwritten/deleted | |
# seamless upgrades/downgrades | |
# $GRADLE_HOME points to latest *installed* (not released) | |
gradle_version=2.9 | |
wget -N https://services.gradle.org/distributions/gradle-${gradle_version}-all.zip | |
sudo unzip -foq gradle-${gradle_version}-all.zip -d /opt/gradle | |
sudo ln -sfn gradle-${gradle_version} /opt/gradle/latest | |
sudo printf "export GRADLE_HOME=/opt/gradle/latest\nexport PATH=\$PATH:\$GRADLE_HOME/bin" > /etc/profile.d/gradle.sh | |
. /etc/profile.d/gradle.sh |