]> git.apps.os.sepia.ceph.com Git - ceph-build.git/commitdiff
import ceph-setup jjb task
authorKen Dreyer <kdreyer@redhat.com>
Tue, 14 Apr 2015 00:10:45 +0000 (18:10 -0600)
committerKen Dreyer <kdreyer@redhat.com>
Tue, 14 Apr 2015 00:11:26 +0000 (18:11 -0600)
This imports the current settings for "ceph-setup" as YAML.

This is an import of the job previously defined in Jenkins' own data
store (ie /home2/jenkins/jobs/ceph-setup/config.xml)

Signed-off-by: Ken Dreyer <kdreyer@redhat.com>
ceph-setup/build/build [new file with mode: 0644]
ceph-setup/config/definitions/ceph-setup.yml [new file with mode: 0644]

diff --git a/ceph-setup/build/build b/ceph-setup/build/build
new file mode 100644 (file)
index 0000000..10f6438
--- /dev/null
@@ -0,0 +1,78 @@
+#!/bin/sh
+
+#export GNUPGHOME=/home/jenkins-build/build/gnupg.autobuild/
+export GNUPGHOME=/home/jenkins-build/build/gnupg.ceph-release/
+export KEYID=17ED316D
+HOST=$(hostname --short)
+echo "Building on ${HOST}"
+echo "  DIST=${DIST}"
+echo "  BPTAG=${BPTAG}"
+echo "  KEYID=${KEYID}"
+echo "  WS=$WORKSPACE"
+echo "  PWD=$(pwd)"
+echo "  BRANCH=$BRANCH"
+
+if [ -x "$BRANCH" ] ; then 
+    echo "No git branch was supplied"
+    exit 1
+fi
+
+echo "Building version $(git describe) Branch $Branch"
+
+if [ ! -d /srv/ceph-build ] ; then
+    echo "Build tools are not installed"
+    exit 1
+fi
+bindir=/srv/ceph-build
+rm -rf dist
+rm -rf release
+
+# fix version/release.  Hack needed only for the spec
+# file for rc candidates.
+#export force=force
+#sed -i 's/^Version:.*/Version:        0.80/' ceph.spec.in
+#sed -i 's/^Release:.*/Release:        rc1%{?dist}/' ceph.spec.in
+#sed -i 's/^Source0:.*/Source0:        http:\/\/ceph.com\/download\/%{name}-%{version}-rc1.tar.bz2/' ceph.spec.in
+#sed -i 's/^%setup.*/%setup -q -n %{name}-%{version}-rc1/' ceph.spec.in
+
+# run submodule updates regardless
+echo "Running submodule update ..."
+git submodule update --init
+
+echo "Running configure ..."
+# because this is running in a Debian-based distro we need to pass -L
+# to disable lttng
+./do_autogen.sh -L
+
+if [ $? -ne 0 ] ; then
+    echo "autogen failed"
+    exit 1
+fi
+
+mkdir -p release
+$bindir/release_tarball.sh release release/version
+if [ $? -ne 0] ; then
+    echo "make tarballs failed"
+    exit 2
+fi
+vers=`cat release/version`
+
+(
+    cd release/$vers
+    #mv debian ceph-$vers/.
+    dpkg-source -b ceph-$vers
+)
+
+mkdir -p dist
+# Debian Source Files
+mv release/$vers/*.dsc dist/.
+mv release/$vers/*.diff.gz dist/.
+mv release/$vers/*.orig.tar.gz dist/.
+# RPM Source Files
+mkdir -p dist/rpm/
+mv release/$vers/rpm/*.patch dist/rpm/ || true
+mv release/$vers/ceph.spec dist/.
+mv release/$vers/*.tar.* dist/.
+# Parameters
+mv release/version dist/.
+exit 0
diff --git a/ceph-setup/config/definitions/ceph-setup.yml b/ceph-setup/config/definitions/ceph-setup.yml
new file mode 100644 (file)
index 0000000..475f986
--- /dev/null
@@ -0,0 +1,39 @@
+- job:
+    name: ceph-setup
+    description: "This job step checks out the branch and builds the tarballs, diffs, and dsc that are passed to the ceph-build step.\r\n\r\nNotes:\r\nJob needs to run on a releatively recent debian system.  The Restrict where run feature is used to specifiy an appropriate label.\r\nThe clear workspace before checkout box for the git plugin is used."
+    node: gitbuilder-cdep-deb-cloud-precise-amd64-basic
+    disabled: false
+    display-name: 'ceph-setup'
+    concurrent: false
+    logrotate:
+      daysToKeep: -1
+      numToKeep: 25
+      artifactDaysToKeep: -1
+      artifactNumToKeep: -1
+    block-downstream: false
+    block-upstream: false
+    properties:
+      - github:
+          url: https://github.com/ceph/ceph
+
+    parameters:
+      - string:
+          name: BRANCH
+          description: "The git branch (or tag) to build"
+
+    scm:
+      - git:
+          url: git://jenkins.front.sepia.ceph.com/ceph/ceph.git
+          branches:
+            - $BRANCH
+
+    builders:
+      - shell: "pwd"
+      - shell:
+          !include-raw ../../build/build
+
+    publishers:
+      - archive:
+          artifacts: 'dist/**'
+          allow-empty: false
+          latest-only: false