add clean script
This commit is contained in:
parent
63f84bbfb6
commit
a4e6d13656
2 changed files with 34 additions and 3 deletions
21
tools/jenkins/jenkins_home/clean.sh
Executable file
21
tools/jenkins/jenkins_home/clean.sh
Executable file
|
@ -0,0 +1,21 @@
|
||||||
|
#!/bin/bash
|
||||||
|
# This script is not yet for general consumption.
|
||||||
|
|
||||||
|
set -o errexit
|
||||||
|
|
||||||
|
if [ ! "$FORCE" = 1 ]; then
|
||||||
|
echo "FORCE not set to 1. Make sure this is something you really want to do. Exiting."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
exit
|
||||||
|
virsh list | cut -d " " -f1 | grep -v "-" | egrep -e "[0-9]" | xargs -n 1 virsh destroy || true
|
||||||
|
virsh net-list | grep active | cut -d " " -f1 | xargs -n 1 virsh net-destroy || true
|
||||||
|
killall dnsmasq
|
||||||
|
rm -rf jobs
|
||||||
|
rm /var/lib/jenkins/jobs
|
||||||
|
git checkout -f
|
||||||
|
git fetch
|
||||||
|
git merge origin/jenkins
|
||||||
|
./build_jenkins.sh
|
||||||
|
|
|
@ -3,7 +3,17 @@
|
||||||
<actions/>
|
<actions/>
|
||||||
<description></description>
|
<description></description>
|
||||||
<keepDependencies>false</keepDependencies>
|
<keepDependencies>false</keepDependencies>
|
||||||
<properties/>
|
<properties>
|
||||||
|
<hudson.model.ParametersDefinitionProperty>
|
||||||
|
<parameterDefinitions>
|
||||||
|
<hudson.model.StringParameterDefinition>
|
||||||
|
<name>RC</name>
|
||||||
|
<description></description>
|
||||||
|
<defaultValue></defaultValue>
|
||||||
|
</hudson.model.StringParameterDefinition>
|
||||||
|
</parameterDefinitions>
|
||||||
|
</hudson.model.ParametersDefinitionProperty>
|
||||||
|
</properties>
|
||||||
<scm class="hudson.plugins.git.GitSCM">
|
<scm class="hudson.plugins.git.GitSCM">
|
||||||
<configVersion>2</configVersion>
|
<configVersion>2</configVersion>
|
||||||
<userRemoteConfigs>
|
<userRemoteConfigs>
|
||||||
|
@ -58,12 +68,12 @@
|
||||||
<hudson.tasks.Shell>
|
<hudson.tasks.Shell>
|
||||||
<command>set -o errexit
|
<command>set -o errexit
|
||||||
cd tools/jenkins
|
cd tools/jenkins
|
||||||
sudo ./build_configuration.sh $EXECUTOR_NUMBER kvm $ADAPTER</command>
|
sudo ./build_configuration.sh $EXECUTOR_NUMBER kvm $ADAPTER "$RC"</command>
|
||||||
</hudson.tasks.Shell>
|
</hudson.tasks.Shell>
|
||||||
<hudson.tasks.Shell>
|
<hudson.tasks.Shell>
|
||||||
<command>set -o errexit
|
<command>set -o errexit
|
||||||
cd tools/jenkins
|
cd tools/jenkins
|
||||||
sudo ./run_test.sh $EXECUTOR_NUMBER $ADAPTER</command>
|
sudo ./run_test.sh $EXECUTOR_NUMBER $ADAPTER $RC "$RC"</command>
|
||||||
</hudson.tasks.Shell>
|
</hudson.tasks.Shell>
|
||||||
</builders>
|
</builders>
|
||||||
<publishers/>
|
<publishers/>
|
||||||
|
|
Loading…
Reference in a new issue