Remove venv jobs.
Change-Id: I61e798c12e78fdf8394394668df1536cc6797246
This commit is contained in:
parent
730d4c09d3
commit
03714cc841
modules
jenkins_jobs/files
jenkins_slave/files/slave_scripts
@ -34,14 +34,6 @@ class builders(object):
|
||||
shell = XML.SubElement(xml_parent, 'hudson.tasks.Shell')
|
||||
XML.SubElement(shell, 'command').text = script
|
||||
|
||||
def _copy_bundle(self, xml_parent):
|
||||
copy = XML.SubElement(xml_parent, 'hudson.plugins.copyartifact.CopyArtifact')
|
||||
XML.SubElement(copy, 'projectName').text = '$PROJECT-venv'
|
||||
XML.SubElement(copy, 'filter')
|
||||
XML.SubElement(copy, 'target')
|
||||
XML.SubElement(copy, 'selector', {'class':'hudson.plugins.copyartifact.StatusBuildSelector'})
|
||||
self._add_script(xml_parent, '/usr/local/jenkins/slave_scripts/copy-bundle.sh')
|
||||
|
||||
def _coverage(self, xml_parent):
|
||||
self._add_script(xml_parent, '/usr/local/jenkins/slave_scripts/run-cover.sh')
|
||||
|
||||
@ -61,16 +53,14 @@ class builders(object):
|
||||
self._add_script(xml_parent, '/usr/local/jenkins/slave_scripts/run-tox.sh 27')
|
||||
|
||||
def _tarball(self, xml_parent):
|
||||
self._add_script(xml_parent, '/usr/local/jenkins/slave_scripts/create-tarball.sh')
|
||||
|
||||
def _venv(self, xml_parent):
|
||||
self._add_script(xml_parent, '/usr/local/jenkins/slave_scripts/build-bundle.sh')
|
||||
self._add_script(xml_parent,
|
||||
'/usr/local/jenkins/slave_scripts/create-tarball.sh %s' % self.data['project'])
|
||||
|
||||
def _ppa(self, xml_parent):
|
||||
self._add_script(xml_parent, 'rm -rf build dist.zip\n\
|
||||
mkdir build')
|
||||
copy = XML.SubElement(xml_parent, 'hudson.plugins.copyartifact.CopyArtifact')
|
||||
XML.SubElement(copy, 'projectName').text = '$PROJECT-tarball'
|
||||
XML.SubElement(copy, 'projectName').text = '%s-tarball' % self.data['project']
|
||||
XML.SubElement(copy, 'filter').text = 'dist/*.tar.gz'
|
||||
XML.SubElement(copy, 'target').text = 'build'
|
||||
selector = XML.SubElement(copy, 'selector', {'class':'hudson.plugins.copyartifact.StatusBuildSelector'})
|
||||
|
@ -35,10 +35,6 @@ class properties(object):
|
||||
XML.SubElement(throttle, 'throttleEnabled').text = 'false'
|
||||
XML.SubElement(throttle, 'throttleOption').text = 'project'
|
||||
XML.SubElement(throttle, 'configVersion').text = '1'
|
||||
env = XML.SubElement(properties, 'EnvInjectJobProperty')
|
||||
einfo = XML.SubElement(env, 'info')
|
||||
eiproperties = XML.SubElement(einfo, 'propertiesContent')
|
||||
eiproperties.text = 'PROJECT={project}'.format(project=main['project'])
|
||||
XML.SubElement(einfo, 'loadFilesFromMaster').text = 'false'
|
||||
XML.SubElement(env, 'on').text = 'true'
|
||||
XML.SubElement(env, 'keepJenkinsSystemVariables').text = 'true'
|
||||
|
@ -1,29 +0,0 @@
|
||||
#! /usr/bin/env python
|
||||
# Copyright (C) 2012 OpenStack, LLC.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
||||
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
# Jenkins Job module for venv publishers
|
||||
# No additional YAML needed
|
||||
|
||||
import xml.etree.ElementTree as XML
|
||||
|
||||
class publisher_venv(object):
|
||||
def __init__(self, data):
|
||||
self.data = data
|
||||
|
||||
def gen_xml(self, xml_parent):
|
||||
publishers = XML.SubElement(xml_parent, 'publishers')
|
||||
archiver = XML.SubElement(publishers, 'hudson.tasks.ArtifactArchiver')
|
||||
XML.SubElement(archiver, 'artifacts').text = 'jenkins_venvs/**/.cache.bundle'
|
||||
XML.SubElement(archiver, 'latestOnly').text = 'false'
|
@ -161,35 +161,6 @@ scm:
|
||||
assignednode:
|
||||
node: 'oneiric'
|
||||
|
||||
---
|
||||
# venv
|
||||
modules:
|
||||
- properties
|
||||
- scm
|
||||
- assignednode
|
||||
- trigger_pollscm
|
||||
- builders
|
||||
- publisher_venv
|
||||
|
||||
main:
|
||||
name: '@NAME@-venv'
|
||||
site: '@SITE@'
|
||||
project: '@NAME@'
|
||||
authenticatedBuild: 'false'
|
||||
disabled: '@DISABLED@'
|
||||
|
||||
trigger:
|
||||
pollscm: '@midnight'
|
||||
|
||||
builders:
|
||||
- venv
|
||||
|
||||
scm:
|
||||
scm: 'true'
|
||||
|
||||
assignednode:
|
||||
node: 'oneiric'
|
||||
|
||||
---
|
||||
# docs
|
||||
modules:
|
||||
|
@ -1,31 +0,0 @@
|
||||
#!/bin/bash -xe
|
||||
|
||||
# Make sure there is a location on this builder to cache pip downloads
|
||||
mkdir -p ~/cache/pip
|
||||
export PIP_DOWNLOAD_CACHE=~/cache/pip
|
||||
|
||||
# Start with a clean slate
|
||||
rm -fr jenkins_venvs
|
||||
mkdir -p jenkins_venvs
|
||||
|
||||
# Build a venv for every known branch
|
||||
for branch in `git branch -r |grep "origin/"|grep -v HEAD|sed "s/origin\///"`
|
||||
do
|
||||
echo "Building venv for $branch"
|
||||
git checkout $branch
|
||||
mkdir -p jenkins_venvs/$branch
|
||||
bundle=jenkins_venvs/$branch/.cache.bundle
|
||||
|
||||
REQUIRES="$@"
|
||||
if [ -f tools/pip-requires ] ; then
|
||||
REQUIRES="${REQUIRES} -r tools/pip-requires"
|
||||
fi
|
||||
if [ -f tools/test-requires ] ; then
|
||||
REQUIRES="${REQUIRES} -r tools/test-requires"
|
||||
fi
|
||||
if [ -z "${REQUIRES}"] ; then
|
||||
REQUIRES="distribute"
|
||||
fi
|
||||
pip bundle $bundle $REQUIRES
|
||||
done
|
||||
git checkout master
|
@ -1,15 +0,0 @@
|
||||
#!/bin/bash -xe
|
||||
|
||||
# Support jobs, such as nova-docs, which are not yet triggered by gerrit
|
||||
if [ "x$GERRIT_BRANCH" = "x" ] ; then
|
||||
GERRIT_BRANCH=master
|
||||
fi
|
||||
mv jenkins_venvs/$GERRIT_BRANCH/.cache.bundle .
|
||||
rm -fr jenkins_venvs
|
||||
|
||||
if [ -f tools/test-requires -a \
|
||||
`git diff HEAD^1 tools/test-requires 2>/dev/null | wc -l` -gt 0 -o \
|
||||
`git diff HEAD^1 tools/pip-requires 2>/dev/null | wc -l` -gt 0 ]
|
||||
then
|
||||
rm .cache.bundle
|
||||
fi
|
@ -17,11 +17,12 @@ fi
|
||||
# Should be + if tarball version is already released and we're moving forward after it.
|
||||
SEPARATOR=${SEPARATOR:-'~'}
|
||||
|
||||
if [ -z "$PROJECT" ]
|
||||
if [ -z "$1" ]
|
||||
then
|
||||
echo '$PROJECT not set.'
|
||||
echo '$1 not set.'
|
||||
exit 1
|
||||
fi
|
||||
PROJECT=$1
|
||||
|
||||
find_next_version() {
|
||||
datestamp="${datestamp:-$(date +%Y%m%d)}"
|
||||
|
Loading…
x
Reference in New Issue
Block a user