| 4 | 1 |
deleted file mode 100755 |
| ... | ... |
@@ -1,69 +0,0 @@ |
| 1 |
-#!/bin/bash |
|
| 2 |
- |
|
| 3 |
-# Echo commands, exit on error |
|
| 4 |
-set -o xtrace |
|
| 5 |
-set -o errexit |
|
| 6 |
- |
|
| 7 |
-# Make sure only root can run our script |
|
| 8 |
-if [[ $EUID -ne 0 ]]; then |
|
| 9 |
- echo "This script must be run as root" |
|
| 10 |
- exit 1 |
|
| 11 |
-fi |
|
| 12 |
- |
|
| 13 |
-# This directory |
|
| 14 |
-CUR_DIR=$(cd $(dirname "$0") && pwd) |
|
| 15 |
- |
|
| 16 |
-# Install software |
|
| 17 |
-DEPS="jenkins" |
|
| 18 |
-apt-get install -y --force-yes $DEPS |
|
| 19 |
- |
|
| 20 |
-# Install jenkins |
|
| 21 |
-if [ ! -e /var/lib/jenkins ]; then |
|
| 22 |
- echo "Jenkins installation failed" |
|
| 23 |
- exit 1 |
|
| 24 |
-fi |
|
| 25 |
- |
|
| 26 |
-# Setup sudo |
|
| 27 |
-JENKINS_SUDO=/etc/sudoers.d/jenkins |
|
| 28 |
-cat > $JENKINS_SUDO <<EOF |
|
| 29 |
-jenkins ALL = NOPASSWD: ALL |
|
| 30 |
-EOF |
|
| 31 |
-chmod 440 $JENKINS_SUDO |
|
| 32 |
- |
|
| 33 |
-# Setup .gitconfig |
|
| 34 |
-JENKINS_GITCONF=/var/lib/jenkins/hudson.plugins.git.GitSCM.xml |
|
| 35 |
-cat > $JENKINS_GITCONF <<EOF |
|
| 36 |
-<?xml version='1.0' encoding='UTF-8'?> |
|
| 37 |
-<hudson.plugins.git.GitSCM_-DescriptorImpl> |
|
| 38 |
- <generation>4</generation> |
|
| 39 |
- <globalConfigName>Jenkins</globalConfigName> |
|
| 40 |
- <globalConfigEmail>jenkins@rcb.me</globalConfigEmail> |
|
| 41 |
-</hudson.plugins.git.GitSCM_-DescriptorImpl> |
|
| 42 |
-EOF |
|
| 43 |
- |
|
| 44 |
-# Set ownership to jenkins |
|
| 45 |
-chown -R jenkins $CUR_DIR |
|
| 46 |
- |
|
| 47 |
-# Set up jobs symlink |
|
| 48 |
-if [ ! -h /var/lib/jenkins/jobs ]; then |
|
| 49 |
- echo "Installing jobs symlink" |
|
| 50 |
- if [ -d /var/lib/jenkins/jobs ]; then |
|
| 51 |
- mv /var/lib/jenkins/jobs /var/lib/jenkins/jobs.old |
|
| 52 |
- fi |
|
| 53 |
- ln -s $CUR_DIR/jobs /var/lib/jenkins/jobs |
|
| 54 |
-fi |
|
| 55 |
- |
|
| 56 |
-# List of plugins |
|
| 57 |
-PLUGINS=http://hudson-ci.org/downloads/plugins/build-timeout/1.6/build-timeout.hpi,http://mirrors.jenkins-ci.org/plugins/git/1.1.12/git.hpi,http://hudson-ci.org/downloads/plugins/global-build-stats/1.2/global-build-stats.hpi,http://hudson-ci.org/downloads/plugins/greenballs/1.10/greenballs.hpi,http://download.hudson-labs.org/plugins/console-column-plugin/1.0/console-column-plugin.hpi |
|
| 58 |
- |
|
| 59 |
-# Configure plugins |
|
| 60 |
-for plugin in ${PLUGINS//,/ }; do
|
|
| 61 |
- name=`basename $plugin` |
|
| 62 |
- dest=/var/lib/jenkins/plugins/$name |
|
| 63 |
- if [ ! -e $dest ]; then |
|
| 64 |
- curl -L $plugin -o $dest |
|
| 65 |
- fi |
|
| 66 |
-done |
|
| 67 |
- |
|
| 68 |
-# Restart jenkins |
|
| 69 |
-restart jenkins |
| 70 | 1 |
deleted file mode 100644 |
| ... | ... |
@@ -1,72 +0,0 @@ |
| 1 |
-<?xml version='1.0' encoding='UTF-8'?> |
|
| 2 |
-<matrix-project> |
|
| 3 |
- <actions/> |
|
| 4 |
- <description></description> |
|
| 5 |
- <keepDependencies>false</keepDependencies> |
|
| 6 |
- <properties/> |
|
| 7 |
- <scm class="hudson.plugins.git.GitSCM"> |
|
| 8 |
- <configVersion>2</configVersion> |
|
| 9 |
- <userRemoteConfigs> |
|
| 10 |
- <hudson.plugins.git.UserRemoteConfig> |
|
| 11 |
- <name>origin</name> |
|
| 12 |
- <refspec>+refs/heads/*:refs/remotes/origin/*</refspec> |
|
| 13 |
- <url>git://github.com/cloudbuilders/devstack.git</url> |
|
| 14 |
- </hudson.plugins.git.UserRemoteConfig> |
|
| 15 |
- </userRemoteConfigs> |
|
| 16 |
- <branches> |
|
| 17 |
- <hudson.plugins.git.BranchSpec> |
|
| 18 |
- <name>jenkins</name> |
|
| 19 |
- </hudson.plugins.git.BranchSpec> |
|
| 20 |
- </branches> |
|
| 21 |
- <recursiveSubmodules>false</recursiveSubmodules> |
|
| 22 |
- <doGenerateSubmoduleConfigurations>false</doGenerateSubmoduleConfigurations> |
|
| 23 |
- <authorOrCommitter>false</authorOrCommitter> |
|
| 24 |
- <clean>false</clean> |
|
| 25 |
- <wipeOutWorkspace>false</wipeOutWorkspace> |
|
| 26 |
- <pruneBranches>false</pruneBranches> |
|
| 27 |
- <remotePoll>false</remotePoll> |
|
| 28 |
- <buildChooser class="hudson.plugins.git.util.DefaultBuildChooser"/> |
|
| 29 |
- <gitTool>Default</gitTool> |
|
| 30 |
- <submoduleCfg class="list"/> |
|
| 31 |
- <relativeTargetDir></relativeTargetDir> |
|
| 32 |
- <excludedRegions></excludedRegions> |
|
| 33 |
- <excludedUsers></excludedUsers> |
|
| 34 |
- <gitConfigName></gitConfigName> |
|
| 35 |
- <gitConfigEmail></gitConfigEmail> |
|
| 36 |
- <skipTag>false</skipTag> |
|
| 37 |
- <scmName></scmName> |
|
| 38 |
- </scm> |
|
| 39 |
- <canRoam>true</canRoam> |
|
| 40 |
- <disabled>false</disabled> |
|
| 41 |
- <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 42 |
- <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 43 |
- <triggers class="vector"/> |
|
| 44 |
- <concurrentBuild>false</concurrentBuild> |
|
| 45 |
- <axes> |
|
| 46 |
- <hudson.matrix.TextAxis> |
|
| 47 |
- <name>ADAPTER</name> |
|
| 48 |
- <values> |
|
| 49 |
- <string>euca</string> |
|
| 50 |
- <string>floatingips</string> |
|
| 51 |
- </values> |
|
| 52 |
- </hudson.matrix.TextAxis> |
|
| 53 |
- </axes> |
|
| 54 |
- <builders> |
|
| 55 |
- <hudson.tasks.Shell> |
|
| 56 |
- <command>sed -i 's/) 2>&1 | tee "${LOGFILE}"/)/' stack.sh</command>
|
|
| 57 |
- </hudson.tasks.Shell> |
|
| 58 |
- <hudson.tasks.Shell> |
|
| 59 |
- <command>set -o errexit |
|
| 60 |
-cd tools/jenkins |
|
| 61 |
-sudo ./build_configuration.sh $EXECUTOR_NUMBER kvm</command> |
|
| 62 |
- </hudson.tasks.Shell> |
|
| 63 |
- <hudson.tasks.Shell> |
|
| 64 |
- <command>set -o errexit |
|
| 65 |
-cd tools/jenkins |
|
| 66 |
-sudo ./run_test.sh $EXECUTOR_NUMBER $ADAPTER</command> |
|
| 67 |
- </hudson.tasks.Shell> |
|
| 68 |
- </builders> |
|
| 69 |
- <publishers/> |
|
| 70 |
- <buildWrappers/> |
|
| 71 |
- <runSequentially>false</runSequentially> |
|
| 72 |
-</matrix-project> |
|
| 73 | 1 |
\ No newline at end of file |
| 74 | 2 |
deleted file mode 100644 |
| ... | ... |
@@ -1,15 +0,0 @@ |
| 1 |
-<?xml version='1.0' encoding='UTF-8'?> |
|
| 2 |
-<matrix-config> |
|
| 3 |
- <keepDependencies>false</keepDependencies> |
|
| 4 |
- <properties/> |
|
| 5 |
- <scm class="hudson.scm.NullSCM"/> |
|
| 6 |
- <canRoam>false</canRoam> |
|
| 7 |
- <disabled>false</disabled> |
|
| 8 |
- <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 9 |
- <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 10 |
- <triggers class="vector"/> |
|
| 11 |
- <concurrentBuild>false</concurrentBuild> |
|
| 12 |
- <builders/> |
|
| 13 |
- <publishers/> |
|
| 14 |
- <buildWrappers/> |
|
| 15 |
-</matrix-config> |
|
| 16 | 1 |
\ No newline at end of file |
| 17 | 2 |
deleted file mode 100644 |
| ... | ... |
@@ -1,15 +0,0 @@ |
| 1 |
-<?xml version='1.0' encoding='UTF-8'?> |
|
| 2 |
-<matrix-config> |
|
| 3 |
- <keepDependencies>false</keepDependencies> |
|
| 4 |
- <properties/> |
|
| 5 |
- <scm class="hudson.scm.NullSCM"/> |
|
| 6 |
- <canRoam>false</canRoam> |
|
| 7 |
- <disabled>false</disabled> |
|
| 8 |
- <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 9 |
- <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 10 |
- <triggers class="vector"/> |
|
| 11 |
- <concurrentBuild>false</concurrentBuild> |
|
| 12 |
- <builders/> |
|
| 13 |
- <publishers/> |
|
| 14 |
- <buildWrappers/> |
|
| 15 |
-</matrix-config> |
|
| 16 | 1 |
\ No newline at end of file |
| 0 | 3 |
new file mode 100755 |
| ... | ... |
@@ -0,0 +1,69 @@ |
| 0 |
+#!/bin/bash |
|
| 1 |
+ |
|
| 2 |
+# Echo commands, exit on error |
|
| 3 |
+set -o xtrace |
|
| 4 |
+set -o errexit |
|
| 5 |
+ |
|
| 6 |
+# Make sure only root can run our script |
|
| 7 |
+if [[ $EUID -ne 0 ]]; then |
|
| 8 |
+ echo "This script must be run as root" |
|
| 9 |
+ exit 1 |
|
| 10 |
+fi |
|
| 11 |
+ |
|
| 12 |
+# This directory |
|
| 13 |
+CUR_DIR=$(cd $(dirname "$0") && pwd) |
|
| 14 |
+ |
|
| 15 |
+# Install software |
|
| 16 |
+DEPS="jenkins" |
|
| 17 |
+apt-get install -y --force-yes $DEPS |
|
| 18 |
+ |
|
| 19 |
+# Install jenkins |
|
| 20 |
+if [ ! -e /var/lib/jenkins ]; then |
|
| 21 |
+ echo "Jenkins installation failed" |
|
| 22 |
+ exit 1 |
|
| 23 |
+fi |
|
| 24 |
+ |
|
| 25 |
+# Setup sudo |
|
| 26 |
+JENKINS_SUDO=/etc/sudoers.d/jenkins |
|
| 27 |
+cat > $JENKINS_SUDO <<EOF |
|
| 28 |
+jenkins ALL = NOPASSWD: ALL |
|
| 29 |
+EOF |
|
| 30 |
+chmod 440 $JENKINS_SUDO |
|
| 31 |
+ |
|
| 32 |
+# Setup .gitconfig |
|
| 33 |
+JENKINS_GITCONF=/var/lib/jenkins/hudson.plugins.git.GitSCM.xml |
|
| 34 |
+cat > $JENKINS_GITCONF <<EOF |
|
| 35 |
+<?xml version='1.0' encoding='UTF-8'?> |
|
| 36 |
+<hudson.plugins.git.GitSCM_-DescriptorImpl> |
|
| 37 |
+ <generation>4</generation> |
|
| 38 |
+ <globalConfigName>Jenkins</globalConfigName> |
|
| 39 |
+ <globalConfigEmail>jenkins@rcb.me</globalConfigEmail> |
|
| 40 |
+</hudson.plugins.git.GitSCM_-DescriptorImpl> |
|
| 41 |
+EOF |
|
| 42 |
+ |
|
| 43 |
+# Set ownership to jenkins |
|
| 44 |
+chown -R jenkins $CUR_DIR |
|
| 45 |
+ |
|
| 46 |
+# Set up jobs symlink |
|
| 47 |
+if [ ! -h /var/lib/jenkins/jobs ]; then |
|
| 48 |
+ echo "Installing jobs symlink" |
|
| 49 |
+ if [ -d /var/lib/jenkins/jobs ]; then |
|
| 50 |
+ mv /var/lib/jenkins/jobs /var/lib/jenkins/jobs.old |
|
| 51 |
+ fi |
|
| 52 |
+ ln -s $CUR_DIR/jobs /var/lib/jenkins/jobs |
|
| 53 |
+fi |
|
| 54 |
+ |
|
| 55 |
+# List of plugins |
|
| 56 |
+PLUGINS=http://hudson-ci.org/downloads/plugins/build-timeout/1.6/build-timeout.hpi,http://mirrors.jenkins-ci.org/plugins/git/1.1.12/git.hpi,http://hudson-ci.org/downloads/plugins/global-build-stats/1.2/global-build-stats.hpi,http://hudson-ci.org/downloads/plugins/greenballs/1.10/greenballs.hpi,http://download.hudson-labs.org/plugins/console-column-plugin/1.0/console-column-plugin.hpi |
|
| 57 |
+ |
|
| 58 |
+# Configure plugins |
|
| 59 |
+for plugin in ${PLUGINS//,/ }; do
|
|
| 60 |
+ name=`basename $plugin` |
|
| 61 |
+ dest=/var/lib/jenkins/plugins/$name |
|
| 62 |
+ if [ ! -e $dest ]; then |
|
| 63 |
+ curl -L $plugin -o $dest |
|
| 64 |
+ fi |
|
| 65 |
+done |
|
| 66 |
+ |
|
| 67 |
+# Restart jenkins |
|
| 68 |
+restart jenkins |
| 0 | 69 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,72 @@ |
| 0 |
+<?xml version='1.0' encoding='UTF-8'?> |
|
| 1 |
+<matrix-project> |
|
| 2 |
+ <actions/> |
|
| 3 |
+ <description></description> |
|
| 4 |
+ <keepDependencies>false</keepDependencies> |
|
| 5 |
+ <properties/> |
|
| 6 |
+ <scm class="hudson.plugins.git.GitSCM"> |
|
| 7 |
+ <configVersion>2</configVersion> |
|
| 8 |
+ <userRemoteConfigs> |
|
| 9 |
+ <hudson.plugins.git.UserRemoteConfig> |
|
| 10 |
+ <name>origin</name> |
|
| 11 |
+ <refspec>+refs/heads/*:refs/remotes/origin/*</refspec> |
|
| 12 |
+ <url>git://github.com/cloudbuilders/devstack.git</url> |
|
| 13 |
+ </hudson.plugins.git.UserRemoteConfig> |
|
| 14 |
+ </userRemoteConfigs> |
|
| 15 |
+ <branches> |
|
| 16 |
+ <hudson.plugins.git.BranchSpec> |
|
| 17 |
+ <name>jenkins</name> |
|
| 18 |
+ </hudson.plugins.git.BranchSpec> |
|
| 19 |
+ </branches> |
|
| 20 |
+ <recursiveSubmodules>false</recursiveSubmodules> |
|
| 21 |
+ <doGenerateSubmoduleConfigurations>false</doGenerateSubmoduleConfigurations> |
|
| 22 |
+ <authorOrCommitter>false</authorOrCommitter> |
|
| 23 |
+ <clean>false</clean> |
|
| 24 |
+ <wipeOutWorkspace>false</wipeOutWorkspace> |
|
| 25 |
+ <pruneBranches>false</pruneBranches> |
|
| 26 |
+ <remotePoll>false</remotePoll> |
|
| 27 |
+ <buildChooser class="hudson.plugins.git.util.DefaultBuildChooser"/> |
|
| 28 |
+ <gitTool>Default</gitTool> |
|
| 29 |
+ <submoduleCfg class="list"/> |
|
| 30 |
+ <relativeTargetDir></relativeTargetDir> |
|
| 31 |
+ <excludedRegions></excludedRegions> |
|
| 32 |
+ <excludedUsers></excludedUsers> |
|
| 33 |
+ <gitConfigName></gitConfigName> |
|
| 34 |
+ <gitConfigEmail></gitConfigEmail> |
|
| 35 |
+ <skipTag>false</skipTag> |
|
| 36 |
+ <scmName></scmName> |
|
| 37 |
+ </scm> |
|
| 38 |
+ <canRoam>true</canRoam> |
|
| 39 |
+ <disabled>false</disabled> |
|
| 40 |
+ <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 41 |
+ <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 42 |
+ <triggers class="vector"/> |
|
| 43 |
+ <concurrentBuild>false</concurrentBuild> |
|
| 44 |
+ <axes> |
|
| 45 |
+ <hudson.matrix.TextAxis> |
|
| 46 |
+ <name>ADAPTER</name> |
|
| 47 |
+ <values> |
|
| 48 |
+ <string>euca</string> |
|
| 49 |
+ <string>floatingips</string> |
|
| 50 |
+ </values> |
|
| 51 |
+ </hudson.matrix.TextAxis> |
|
| 52 |
+ </axes> |
|
| 53 |
+ <builders> |
|
| 54 |
+ <hudson.tasks.Shell> |
|
| 55 |
+ <command>sed -i 's/) 2>&1 | tee "${LOGFILE}"/)/' stack.sh</command>
|
|
| 56 |
+ </hudson.tasks.Shell> |
|
| 57 |
+ <hudson.tasks.Shell> |
|
| 58 |
+ <command>set -o errexit |
|
| 59 |
+cd tools/jenkins |
|
| 60 |
+sudo ./build_configuration.sh $EXECUTOR_NUMBER kvm</command> |
|
| 61 |
+ </hudson.tasks.Shell> |
|
| 62 |
+ <hudson.tasks.Shell> |
|
| 63 |
+ <command>set -o errexit |
|
| 64 |
+cd tools/jenkins |
|
| 65 |
+sudo ./run_test.sh $EXECUTOR_NUMBER $ADAPTER</command> |
|
| 66 |
+ </hudson.tasks.Shell> |
|
| 67 |
+ </builders> |
|
| 68 |
+ <publishers/> |
|
| 69 |
+ <buildWrappers/> |
|
| 70 |
+ <runSequentially>false</runSequentially> |
|
| 71 |
+</matrix-project> |
|
| 0 | 72 |
\ No newline at end of file |
| 1 | 73 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,15 @@ |
| 0 |
+<?xml version='1.0' encoding='UTF-8'?> |
|
| 1 |
+<matrix-config> |
|
| 2 |
+ <keepDependencies>false</keepDependencies> |
|
| 3 |
+ <properties/> |
|
| 4 |
+ <scm class="hudson.scm.NullSCM"/> |
|
| 5 |
+ <canRoam>false</canRoam> |
|
| 6 |
+ <disabled>false</disabled> |
|
| 7 |
+ <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 8 |
+ <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 9 |
+ <triggers class="vector"/> |
|
| 10 |
+ <concurrentBuild>false</concurrentBuild> |
|
| 11 |
+ <builders/> |
|
| 12 |
+ <publishers/> |
|
| 13 |
+ <buildWrappers/> |
|
| 14 |
+</matrix-config> |
|
| 0 | 15 |
\ No newline at end of file |
| 1 | 16 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,15 @@ |
| 0 |
+<?xml version='1.0' encoding='UTF-8'?> |
|
| 1 |
+<matrix-config> |
|
| 2 |
+ <keepDependencies>false</keepDependencies> |
|
| 3 |
+ <properties/> |
|
| 4 |
+ <scm class="hudson.scm.NullSCM"/> |
|
| 5 |
+ <canRoam>false</canRoam> |
|
| 6 |
+ <disabled>false</disabled> |
|
| 7 |
+ <blockBuildWhenDownstreamBuilding>false</blockBuildWhenDownstreamBuilding> |
|
| 8 |
+ <blockBuildWhenUpstreamBuilding>false</blockBuildWhenUpstreamBuilding> |
|
| 9 |
+ <triggers class="vector"/> |
|
| 10 |
+ <concurrentBuild>false</concurrentBuild> |
|
| 11 |
+ <builders/> |
|
| 12 |
+ <publishers/> |
|
| 13 |
+ <buildWrappers/> |
|
| 14 |
+</matrix-config> |
|
| 0 | 15 |
\ No newline at end of file |