def get_proxy(): info = load() proxy = xmlrpclib.ServerProxy( "http://{user}:{password}@{host}:{port}/".format( user=info['user'], password=info['password'], host=info['host'], port=info['port'] ), allow_none=True) return proxy
def get_proxy(): info = load() proxy = xmlrpclib.ServerProxy( "http://{user}:{password}@{host}:{port}/".format( user=info['user'], password=info['password'], host=info['host'], port=info['port']), allow_none=True) return proxy
def run(debs, package, job, firehose): if any((not x.endswith(".deb") for x in debs)): raise Exception("Non-deb given") config = load() all_arch = config['all-arch'] arch = package['arch'] if package['arch'] == 'all': arch = all_arch chroot_name = "{suite}-{arch}".format(suite=package['suite'], arch=arch) return adequate(chroot_name, debs, firehose)
def run(debs, package, job, firehose): if any((not x.endswith(".deb") for x in debs)): raise Exception("Non-deb given") config = load() all_arch = config["all-arch"] arch = package["arch"] if package["arch"] == "all": arch = all_arch chroot_name = "{suite}-{arch}".format(suite=package["suite"], arch=arch) return adequate(chroot_name, debs, firehose)
def run(debs, package, job, firehose): if any((not x.endswith(".deb") for x in debs)): raise Exception("Non-deb given") config = load() all_arch = config['all-arch'] arch = package['arch'] if package['arch'] == 'all': arch = all_arch chroot_name = "{suite}-{arch}".format( suite=package['suite'], arch=arch ) return piuparts(chroot_name, debs, firehose)
from firehose.model import (Analysis, Generator, Metadata, DebianBinary, DebianSource) from ethel.commands import PLUGINS, load_module from ethel.client import get_proxy, checkout from contextlib import contextmanager from ethel.utils import tdir, cd, run_command from ethel.config import load import logging import time config = load() proxy = get_proxy() class IDidNothingError(Exception): pass def listize(entry): items = [x.strip() for x in entry.split(",")] return [None if x == "null" else x for x in items] @contextmanager def workon(suites, arches, capabilities): job = proxy.get_next_job(suites, arches, capabilities) if job is None: yield else:
from firehose.model import Analysis, Generator, Metadata, DebianBinary, DebianSource from ethel.commands import PLUGINS, load_module from ethel.client import get_proxy, checkout from contextlib import contextmanager from ethel.utils import tdir, cd, run_command from ethel.config import load import logging import time config = load() proxy = get_proxy() class IDidNothingError(Exception): pass def listize(entry): items = [x.strip() for x in entry.split(",")] return [None if x == "null" else x for x in items] @contextmanager def workon(suites, arches, capabilities): job = proxy.get_next_job(suites, arches, capabilities) if job is None: yield else: logging.info("Acquired job %s (%s) for %s/%s", job["_id"], job["type"], job["suite"], job["arch"])