[Qa-jenkins-scm] [jenkins.debian.net] 01/01: reproducible: add job to configure mock for fedora23 on x86_64
Holger Levsen
holger at moszumanska.debian.org
Mon Dec 7 18:43:39 UTC 2015
This is an automated email from the git hooks/post-receive script.
holger pushed a commit to branch master
in repository jenkins.debian.net.
commit 40b8019f210d18fdd069ae57d5a651bfafc504e1
Author: Holger Levsen <holger at layer-acht.org>
Date: Mon Dec 7 19:43:33 2015 +0100
reproducible: add job to configure mock for fedora23 on x86_64
---
bin/jenkins_node_wrapper.sh | 2 ++
bin/reproducible_setup_mock.sh | 23 ++++++++++++++++++++++
.../etc/sudoers.d/jenkins | 3 ++-
job-cfg/reproducible.yaml | 10 ++++++++++
4 files changed, 37 insertions(+), 1 deletion(-)
diff --git a/bin/jenkins_node_wrapper.sh b/bin/jenkins_node_wrapper.sh
index 1bde7fe..c830377 100755
--- a/bin/jenkins_node_wrapper.sh
+++ b/bin/jenkins_node_wrapper.sh
@@ -103,6 +103,8 @@ elif [[ "$*" =~ reproducible_freebsd ]] ; then
exec /srv/jenkins/bin/reproducible_freebsd.sh ; croak "Exec failed";
elif [[ "$*" =~ reproducible_setup_schroot_arch ]] ; then
exec /srv/jenkins/bin/reproducible_arch_schroot_setup.sh ; croak "Exec failed";
+elif [[ "$*" =~ reproducible_setup_mock_fedora23_x86_64 ]] ; then
+ exec /srv/jenkins/bin/reproducible_setup_mock.sh fedora-23 x86_64 ; croak "Exec failed";
elif [ "$1" = "/srv/jenkins/bin/reproducible_build_arch_pkg.sh" ] && ( [ "$2" = "1" ] || [ "$2" = "2" ] ) ; then
exec /srv/jenkins/bin/reproducible_build_arch_pkg.sh "$2" "$3" "$4" ; croak "Exec failed";
elif [ "$*" = "some_jenkins_job_name" ] ; then
diff --git a/bin/reproducible_setup_mock.sh b/bin/reproducible_setup_mock.sh
new file mode 100755
index 0000000..c404eec
--- /dev/null
+++ b/bin/reproducible_setup_mock.sh
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+# Copyright 2015 Holger Levsen <holger at layer-acht.org>
+# released under the GPLv=2
+
+#
+# configures mock for a given distro and architecture
+#
+
+DEBUG=false
+. /srv/jenkins/bin/common-functions.sh
+common_init "$@"
+
+if [ -z "$1" ] || [ -z "$2" ] ; then
+ echo "Need distro and architecture as params"
+ exit 1
+fi
+DISTRO=$1
+ARCHITECTURE=$2
+
+echo "$(date -u) - starting to configure mock for ${DISTRO} on ${ARCHITECTURE} now."
+sudo mock -r ${DISTRO}-${ARCHITECTURE} --init
+echo "$(date -u) - mock configured for ${DISTRO} on ${ARCHITECTURE} now."
diff --git a/hosts/profitbricks-build3-amd64/etc/sudoers.d/jenkins b/hosts/profitbricks-build3-amd64/etc/sudoers.d/jenkins
index a0127b6..cb0c4e6 100644
--- a/hosts/profitbricks-build3-amd64/etc/sudoers.d/jenkins
+++ b/hosts/profitbricks-build3-amd64/etc/sudoers.d/jenkins
@@ -9,7 +9,8 @@ jenkins ALL= \
/bin/rm -rf --one-file-system /srv/live-build/*, \
/bin/mv /schroots/* /schroots/*, \
/bin/umount -l /schroots/*, \
- /bin/mount --bind *
+ /bin/mount --bind *, \
+ /usr/bin/mock -r * --init
# keep these environment variables
Defaults env_keep += "http_proxy", env_reset
diff --git a/job-cfg/reproducible.yaml b/job-cfg/reproducible.yaml
index 9d54ae0..7d282fd 100644
--- a/job-cfg/reproducible.yaml
+++ b/job-cfg/reproducible.yaml
@@ -758,6 +758,10 @@
name: '{name}_setup_schroot_arch'
- job-template:
+ defaults: reproducible_other_projects
+ name: '{name}_setup_mock_fedora23_x86_64'
+
+- job-template:
defaults: reproducible_builder_trigger
name: '{name}_builder_arch_1'
@@ -1521,6 +1525,12 @@
my_shell: '/srv/jenkins/bin/jenkins_master_wrapper.sh'
my_recipients: 'qa-jenkins-scm at lists.alioth.debian.org'
my_node: 'profitbricks3'
+ - '{name}_setup_mock_fedora23_x86_64':
+ my_description: 'Setup mock for fedora23 on X86_64 to test .rpm packages for reproducibility.'
+ my_timed: '42 23 1 1 *'
+ my_shell: '/srv/jenkins/bin/jenkins_master_wrapper.sh'
+ my_recipients: 'qa-jenkins-scm at lists.alioth.debian.org'
+ my_node: 'profitbricks3'
- '{name}_builder_arch_1':
my_description: 'Try to reproducibly build an Arch Linux package.'
my_timed: '* * * * *'
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git
More information about the Qa-jenkins-scm
mailing list