[koji PATCH] allow setting the timeout for builds from config file
by Dan Horák
---
builder/kojid | 5 +++--
builder/kojid.conf | 3 +++
koji/__init__.py | 2 +-
3 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/builder/kojid b/builder/kojid
index f906d0b..18c1fa4 100755
--- a/builder/kojid
+++ b/builder/kojid
@@ -204,7 +204,7 @@ class BuildRoot(object):
for k in ('repoid', 'tag_name'):
if hasattr(self, k):
opts[k] = getattr(self, k)
- for k in ('mockdir', 'topdir', 'topurl', 'topurls', 'packager', 'vendor', 'distribution', 'mockhost', 'yum_proxy'):
+ for k in ('mockdir', 'topdir', 'topurl', 'topurls', 'packager', 'vendor', 'distribution', 'mockhost', 'yum_proxy', 'rpmbuild_timeout'):
if hasattr(self.options, k):
opts[k] = getattr(self.options, k)
opts['buildroot_id'] = self.id
@@ -3060,6 +3060,7 @@ def get_options():
'maven_repo_ignore': '*.md5 *.sha1 maven-metadata*.xml _maven.repositories '
'resolver-status.properties *.lastUpdated',
'failed_buildroot_lifetime' : 3600 * 4,
+ 'rpmbuild_timeout' : 3600 * 24,
'cert': '/etc/kojid/client.crt',
'ca': '/etc/kojid/clientca.crt',
'serverca': '/etc/kojid/serverca.crt'}
@@ -3067,7 +3068,7 @@ def get_options():
for name, value in config.items('kojid'):
if name in ['sleeptime', 'maxjobs', 'minspace', 'retry_interval',
'max_retries', 'offline_retry_interval', 'failed_buildroot_lifetime',
- 'timeout',]:
+ 'timeout', 'rpmbuild_timeout',]:
try:
defaults[name] = int(value)
except ValueError:
diff --git a/builder/kojid.conf b/builder/kojid.conf
index 1fa9ad4..05fe3b0 100644
--- a/builder/kojid.conf
+++ b/builder/kojid.conf
@@ -32,6 +32,9 @@
; The _host string to use in mock
; mockhost=koji-linux-gnu
+; Timeout for build duration (24 hours)
+; rpmbuild_timeout=86400
+
; The URL for the xmlrpc server
server=http://hub.example.com/kojihub
diff --git a/koji/__init__.py b/koji/__init__.py
index f42226b..8ab81a8 100644
--- a/koji/__init__.py
+++ b/koji/__init__.py
@@ -1266,7 +1266,7 @@ def genMockConfig(name, arch, managed=False, repoid=None, tag_name=None, **opts)
# don't encourage network access from the chroot
'use_host_resolv': opts.get('use_host_resolv', False),
# Don't let a build last more than 24 hours
- 'rpmbuild_timeout': 86400
+ 'rpmbuild_timeout': opts.get('rpmbuild_timeout', 86400)
}
# bind_opts are used to mount parts (or all of) /dev if needed.
--
1.7.7.6
10 years, 3 months
Koji-1.7.1-1.fc17 repository toplink failure
by Anthony Joseph Messina
After upgrading to koji-1.7.1 on my private hub and builders, my builders are
no longer able to use the repositories they create when building subsequent
dependent packages. When attempting to install locally built packages, the
following error is issued in the root.log:
error was [Errno 2] Local file does not exist:
/tmp/koji/tasks/9129/19129/repo_3627_premerge/toplink/packages/...
The repos are created successfully:
$ /usr/bin/createrepo -vd -o /tmp/koji/tasks/9129/19129/repo -i
/mnt/koji/repos/f17-build/3627/x86_64/pkglist -g /mnt/koji/repos/f17-
build/3627/groups/comps.xml --update --skip-stat /mnt/koji/repos/f17-
build/3627/x86_64
Scanning old repo data
Spawning worker 0 with 36 pkgs
Worker 0: reading toplink/packages/dahdi-tools/2.6.1/3.fc17.1/x86_64/dahdi-
tools-2.6.1-3.fc17.1.x86_64.rpm
Worker 0: reading toplink/packages/dahdi-tools/2.6.1/3.fc17.1/x86_64/dahdi-
tools-devel-2.6.1-3.fc17.1.x86_64.rpm
Worker 0: reading toplink/packages/dahdi-tools/2.6.1/3.fc17.1/x86_64/dahdi-
tools-libs-2.6.1-3.fc17.1.x86_64.rpm
...
...
I believe the issue is related to the following commit:
https://fedorahosted.org/koji/changeset/da6dd0b1832e9929565a1ab03ab844aac...
I'm not sure why when building packages, the builders are inserting
'/tmp/koji/tasks/9129/19129/repo_3627_premerge/toplink'
instead of topdir or topurl, such as
'/mnt/koji' or 'http://example.com/kojifiles'
Right now I'm working on selectively reverting that commit to see if I can
build packages against other local packages.
Any assistance is appreciated. Thanks. -Anthony
--
Anthony - http://messinet.com - http://messinet.com/~amessina/gallery
8F89 5E72 8DF0 BCF0 10BE 9967 92DC 35DC B001 4A4E
10 years, 8 months
Cannot build RHEL5/F18 packages on Fedora 18
by Michael Cronenworth
I had to build my first RHEL5 and F18 packages today after upgrading my
Koji server from Fedora 17 to 18. I cannot build RHEL5 or F18 packages,
but RHEL6 packages compile fine. All packages built successfully under
Fedora 17.
RHEL5 root.log:
[snip]
DEBUG util.py:264: error reading information on service rdisc: Cannot allocate memory
DEBUG util.py:264: warning: %post(iputils-20020927-46.el5.i386) scriptlet failed, exit status 1
DEBUG util.py:264: Non-fatal POSTIN scriptlet failure in rpm package iputils-20020927-46.el5.i386
DEBUG util.py:264: error reading information on service iscsid: Cannot allocate memory
DEBUG util.py:264: error reading information on service iscsi: Cannot allocate memory
DEBUG util.py:264: warning: %post(iscsi-initiator-utils-6.2.0.872-6.el5.i386) scriptlet failed, exit status 1
DEBUG util.py:264: Non-fatal POSTIN scriptlet failure in rpm package iscsi-initiator-utils-6.2.0.872-6.el5.i386
RHEL5 build.log:
[snip]
gcc: error trying to exec 'cc1': execvp: No such file or directory
F18 build.log:
[snip]
collect2: fatal error: cannot find 'ld'
Is F18's mock broken?
Michael
10 years, 11 months
Kojid plugin for mashing and spacewalk syncing
by Cypher
Hi all,
I'd like to share my plugin for mashing and spacewalk syncing.
Any feedback welcome as I am still new to Koji coding. What could be improved?
TODO:
- return result log files rather than big string, no idea how
- transfer config to plugin config file. can that be done same way as for hub plugins ?
https://github.com/philicious/koji-scripts-and-plugins/blob/master/mash_a...
# Koji Builder (kojid) plugin with two subtasks:
# 0. mash-and-spacewalk - main task
# 1. mash - mashes all packages tagged for testing repo
# 2. spacewalk - syncs the newly mashed repo to spacewalk
Hope someone finds this useful !
10 years, 11 months
Results / Logs in custom Builder TaskHandler
by Cypher
Hi all,
I am currently working on a Builder Plugin. So far its working great but I get my task output in "Result" as I just return it as a string.
However I'd more like it to be under "Output" displaying a logfile with that info in it. Just like build.log, root.log etc
How would I approach this? Which imports do I need?
in kojid I saw it does:
logs = {}
..
logs.setdefault(arch,[]).append(fn)
return srpm,rpms,brmap,logs
How would I adapt that to my task handler ?
Thanks in advance, Phil !
10 years, 11 months
[PATCH 1/2] Change httpd configuration to use httpd 2.4 syntax
by Felix Kaechele
---
hub/httpd.conf | 6 ++----
www/conf/kojiweb.conf | 6 ++----
2 files changed, 4 insertions(+), 8 deletions(-)
diff --git a/hub/httpd.conf b/hub/httpd.conf
index 5ecfb09..0463cd1 100644
--- a/hub/httpd.conf
+++ b/hub/httpd.conf
@@ -7,8 +7,7 @@ Alias /kojihub /usr/share/koji-hub/kojixmlrpc.py
<Directory "/usr/share/koji-hub">
Options ExecCGI
SetHandler wsgi-script
- Order allow,deny
- Allow from all
+ Require all granted
</Directory>
# Support for mod_python is DEPRECATED. If you still need mod_python support,
@@ -28,8 +27,7 @@ Alias /kojifiles "/mnt/koji/"
<Directory "/mnt/koji">
Options Indexes
AllowOverride None
- Order allow,deny
- Allow from all
+ Require all granted
</Directory>
# uncomment this to enable authentication via SSL client certificates
diff --git a/www/conf/kojiweb.conf b/www/conf/kojiweb.conf
index cb75fba..78ed579 100644
--- a/www/conf/kojiweb.conf
+++ b/www/conf/kojiweb.conf
@@ -5,8 +5,7 @@ Alias /koji "/usr/share/koji-web/scripts/wsgi_publisher.py"
<Directory "/usr/share/koji-web/scripts/">
Options ExecCGI
SetHandler wsgi-script
- Order allow,deny
- Allow from all
+ Require all granted
</Directory>
# Support for mod_python is DEPRECATED. If you still need mod_python support,
@@ -51,6 +50,5 @@ Alias /koji-static/ "/usr/share/koji-web/static/"
<Directory "/usr/share/koji-web/static/">
Options None
AllowOverride None
- Order allow,deny
- Allow from all
+ Require all granted
</Directory>
--
1.8.1.4
10 years, 12 months
Cannot use kojiweb or start kojid
by Michael Cronenworth
After an upgrade from F17 to F18, koji-web returns Internal Server Error
and kojid will not start.
The Apache log says:
[Thu Mar 21 09:43:27.114799 2013] [:error] [pid 16669] InternalError:
FATAL: Peer authentication failed for user "koji"
I have verified that /var/lib/pgsql/data/pg_hba.conf contains the
correct entries:
host koji koji 127.0.0.1/32 trust
host koji apache 127.0.0.1/32 trust
host koji koji ::1/128 trust
host koji apache ::1/128 trust
local koji apache trust
local koji koji trust
SELinux is in "permissive" mode.
I can login with the koji user and connect with "psql koji" without a
problem.
Did something change in F18/koji that I need to fix?
Thanks,
Michael
11 years
Single tag multiple %dist
by Thomas
Hi,
Is there an easy trick to be able to build on a single Koji tag different
dist:
joe-1.0-2.el5.src.rpm
douglas-1.2-3.el5_0.src.rpm
-> sent to tag "updates".
By default you get "tag mismatch"
The tag is defined by a buildsys package in my setup.
TIA,
--
Thomas
11 years
move the koji-hub
by Fabrice Cantos
Hi,
I have my own koji build system and I would like to move the koji-hub to an another system.
Do you have a doc link or a howto ?
Or could you tell me the procedure, what to backup/restore, how ?
Thanks in advance,
Fabrice
--
Please consider the environment before printing this email.
NIWA is the trading name of the National Institute of Water & Atmospheric Research Ltd.
11 years
[koji PATCH] allow setting the timeout for builds from config file
by Dan Horák
---
builder/kojid | 3 ++-
builder/kojid.conf | 3 +++
koji/__init__.py | 2 +-
3 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/builder/kojid b/builder/kojid
index f906d0b..6c8a847 100755
--- a/builder/kojid
+++ b/builder/kojid
@@ -204,7 +204,7 @@ class BuildRoot(object):
for k in ('repoid', 'tag_name'):
if hasattr(self, k):
opts[k] = getattr(self, k)
- for k in ('mockdir', 'topdir', 'topurl', 'topurls', 'packager', 'vendor', 'distribution', 'mockhost', 'yum_proxy'):
+ for k in ('mockdir', 'topdir', 'topurl', 'topurls', 'packager', 'vendor', 'distribution', 'mockhost', 'yum_proxy', 'rpmbuild_timeout'):
if hasattr(self.options, k):
opts[k] = getattr(self.options, k)
opts['buildroot_id'] = self.id
@@ -3060,6 +3060,7 @@ def get_options():
'maven_repo_ignore': '*.md5 *.sha1 maven-metadata*.xml _maven.repositories '
'resolver-status.properties *.lastUpdated',
'failed_buildroot_lifetime' : 3600 * 4,
+ 'rpmbuild_timeout' : 3600 * 24,
'cert': '/etc/kojid/client.crt',
'ca': '/etc/kojid/clientca.crt',
'serverca': '/etc/kojid/serverca.crt'}
diff --git a/builder/kojid.conf b/builder/kojid.conf
index 1fa9ad4..05fe3b0 100644
--- a/builder/kojid.conf
+++ b/builder/kojid.conf
@@ -32,6 +32,9 @@
; The _host string to use in mock
; mockhost=koji-linux-gnu
+; Timeout for build duration (24 hours)
+; rpmbuild_timeout=86400
+
; The URL for the xmlrpc server
server=http://hub.example.com/kojihub
diff --git a/koji/__init__.py b/koji/__init__.py
index f42226b..8ab81a8 100644
--- a/koji/__init__.py
+++ b/koji/__init__.py
@@ -1266,7 +1266,7 @@ def genMockConfig(name, arch, managed=False, repoid=None, tag_name=None, **opts)
# don't encourage network access from the chroot
'use_host_resolv': opts.get('use_host_resolv', False),
# Don't let a build last more than 24 hours
- 'rpmbuild_timeout': 86400
+ 'rpmbuild_timeout': opts.get('rpmbuild_timeout', 86400)
}
# bind_opts are used to mount parts (or all of) /dev if needed.
--
1.7.7.6
11 years