2013-12-14 00:18:17 +00:00
|
|
|
# usig a freestyle project to work around jenkins bug:
|
2013-08-14 17:40:43 -07:00
|
|
|
# https://issues.jenkins-ci.org/browse/JENKINS-14193
|
2013-07-12 11:27:57 -07:00
|
|
|
|
2013-04-12 10:18:50 -07:00
|
|
|
- job-template:
|
|
|
|
name: 'gate-{name}-build'
|
2013-12-14 00:18:17 +00:00
|
|
|
node: '{node}'
|
2013-01-11 16:52:50 -08:00
|
|
|
|
2013-06-21 11:12:55 -07:00
|
|
|
wrappers:
|
2014-05-27 14:51:16 -07:00
|
|
|
- build-timeout:
|
2013-07-11 17:31:32 -07:00
|
|
|
timeout: 30
|
|
|
|
- timestamps
|
2013-08-14 17:40:43 -07:00
|
|
|
|
|
|
|
builders:
|
2014-02-11 14:15:13 -08:00
|
|
|
- revoke-sudo
|
2013-08-14 17:40:43 -07:00
|
|
|
- gerrit-git-prep
|
|
|
|
- shell: |
|
|
|
|
#!/bin/bash -xe
|
2014-02-27 15:16:50 -08:00
|
|
|
/usr/local/jenkins/slave_scripts/version-properties.sh
|
2014-06-26 10:16:48 -07:00
|
|
|
source version.properties
|
|
|
|
mvn clean package -B -Dproject-version=$PROJECT_VER
|
2013-01-11 16:52:50 -08:00
|
|
|
|
|
|
|
publishers:
|
|
|
|
- console-log
|
2013-03-18 11:30:14 -07:00
|
|
|
|
2013-04-12 10:18:50 -07:00
|
|
|
- job-template:
|
|
|
|
name: '{name}-hpi-artifact'
|
2013-12-14 00:18:17 +00:00
|
|
|
node: '{node}'
|
2013-03-18 11:30:14 -07:00
|
|
|
|
2013-06-21 11:12:55 -07:00
|
|
|
wrappers:
|
2014-05-27 14:51:16 -07:00
|
|
|
- build-timeout:
|
2013-07-11 17:31:32 -07:00
|
|
|
timeout: 30
|
|
|
|
- timestamps
|
2013-08-14 17:40:43 -07:00
|
|
|
|
|
|
|
builders:
|
2014-02-11 14:15:13 -08:00
|
|
|
- revoke-sudo
|
2013-08-14 17:40:43 -07:00
|
|
|
- gerrit-git-prep
|
|
|
|
- shell: |
|
|
|
|
#!/bin/bash -xe
|
2014-02-27 15:16:50 -08:00
|
|
|
/usr/local/jenkins/slave_scripts/version-properties.sh
|
2014-06-26 10:16:48 -07:00
|
|
|
source version.properties
|
|
|
|
mvn clean package -B -Dproject-version=$PROJECT_VER
|
|
|
|
cp ./target/{name}.hpi ./target/{name}-$PROJECT_VER.hpi
|
2013-07-15 14:25:04 -07:00
|
|
|
|
2013-03-18 11:30:14 -07:00
|
|
|
publishers:
|
|
|
|
- war:
|
2013-12-14 00:18:17 +00:00
|
|
|
site: '{tarball-site}'
|
2014-06-26 10:16:48 -07:00
|
|
|
warfile: 'target/{name}-*.hpi'
|
2013-07-15 14:25:04 -07:00
|
|
|
target: 'tarballs/ci/{name}'
|
2013-07-09 10:53:27 -07:00
|
|
|
- console-log
|
2013-06-12 14:26:41 -07:00
|
|
|
|
|
|
|
- job-template:
|
|
|
|
name: '{name}-jenkinsci-upload'
|
|
|
|
node: pypi
|
|
|
|
|
|
|
|
builders:
|
2014-02-11 14:15:13 -08:00
|
|
|
- revoke-sudo
|
2013-06-12 14:26:41 -07:00
|
|
|
- shell: |
|
|
|
|
#!/bin/bash -xe
|
|
|
|
TAG=`echo $ZUUL_REF | sed 's/^refs.tags.//'`
|
2013-08-06 15:27:29 -07:00
|
|
|
FILENAME_HPI="{name}-$TAG.hpi"
|
2013-06-12 14:26:41 -07:00
|
|
|
|
2013-08-06 15:27:29 -07:00
|
|
|
# copy plugin artifacts from tarballs to local workspace
|
2013-06-12 14:26:41 -07:00
|
|
|
rm -rf *.hpi
|
2013-08-06 15:27:29 -07:00
|
|
|
curl -o $FILENAME_HPI http://{tarball-site}/ci/{name}/$FILENAME_HPI
|
2013-06-12 14:26:41 -07:00
|
|
|
|
2013-08-06 15:27:29 -07:00
|
|
|
# deploy to maven repository
|
|
|
|
FILENAME_POM="{name}-$TAG.pom"
|
|
|
|
/usr/local/jenkins/slave_scripts/jenkinsci-upload.sh {name} $TAG \
|
|
|
|
$FILENAME_POM $FILENAME_HPI
|
2013-06-12 14:26:41 -07:00
|
|
|
|
|
|
|
publishers:
|
2013-07-09 10:53:27 -07:00
|
|
|
- console-log
|
2013-04-12 10:18:50 -07:00
|
|
|
|
|
|
|
- job-group:
|
|
|
|
name: jenkins-plugin-jobs
|
|
|
|
jobs:
|
|
|
|
- 'gate-{name}-build'
|
|
|
|
- '{name}-hpi-artifact'
|
2013-06-12 14:26:41 -07:00
|
|
|
- '{name}-jenkinsci-upload'
|