# Check for external deps
for component in get_components(configuration):
    external_deps_file = component.get('external_deps')
    if external_deps_file:
        external_deps_file = os.path.join(working_dir, component.get('name'), external_deps_file)
        for package_nevra in builder.get_build_names_from_external_deps_file(external_deps_file):
            info = builder.mysession.getBuild(package_nevra)
            if info:
                download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
            else:
                print "External deps requires %s but it could not be found in koji" % package_nevra
                sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(working_dir):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec)
    print "%s %s" % (spec_nvr, package_dists)
    for package_nevra in builder.get_package_nevra(spec_nvr, package_dists):
        info = builder.mysession.getBuild(package_nevra)
        if info:
            download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
        else:
            build_list.append((spec, builder.get_dist_from_koji_build_name(package_nevra)))

# If we are doing a version check, exit here
if opts.show_versions:
    sys.exit(0)

# Match spec files to project
Exemple #2
0
# Check for external deps
# for component in get_components(configuration):
#     external_deps_file = component.get('external_deps')
#     if external_deps_file:
#         external_deps_file = os.path.join(working_dir, component.get('name'), external_deps_file)
#         for package_nevra in builder.get_build_names_from_external_deps_file(external_deps_file):
#             info = builder.mysession.getBuild(package_nevra)
#             if info:
#                 download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
#             else:
#                 print "External deps requires %s but it could not be found in koji" % package_nevra
#                 sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(os.path.join(working_dir, opts.project)):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec)
    print "%s %s" % (spec_nvr, package_dists)
    for package_nevra in builder.get_package_nevra(spec_nvr, package_dists):
        info = builder.mysession.getBuild(package_nevra)
        if info:
            download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra))
        else:
            build_list.append((spec, builder.get_dist_from_koji_build_name(package_nevra)))

# Sort the list by platform so it is easier to spot missing things in the output
download_list = sorted(download_list, key=lambda download: download[1])

# Perform a scratch build of all the unbuilt packages
build_ids = []
Exemple #3
0
# Check for external deps
for component in get_components(configuration):
    external_deps_file = component.get('external_deps')
    if external_deps_file:
        external_deps_file = os.path.join(working_dir, component.get('name'), external_deps_file)
        for package_nevra in builder.get_build_names_from_external_deps_file(external_deps_file):
            info = builder.mysession.getBuild(package_nevra)
            if info:
                download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
            else:
                print "External deps requires %s but it could not be found in koji" % package_nevra
                sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(working_dir):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec)
    print "%s %s" % (spec_nvr, package_dists)
    for package_nevra in builder.get_package_nevra(spec_nvr, package_dists):
        info = builder.mysession.getBuild(package_nevra)
        if info:
            download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
        else:
            build_list.append((spec, builder.get_dist_from_koji_build_name(package_nevra)))

# If we are doing a version check, exit here
if opts.show_versions:
    sys.exit(0)

# Sort the list by platform so it is easier to spot missing things in the output
Exemple #4
0
# Get the project to build from git by spoofing a release config component
component = {
    'name': opts.project,
    'git_url': "[email protected]:pulp/{}.git".format(opts.project),
    'git_branch': opts.branch,
}
project_path = builder.clone_branch(component)

print("Building list of things to build")

download_list = []
build_list = []

# Get all spec files
for spec in builder.find_all_spec_files(project_path):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec)
    print("%s %s" % (spec_nvr, package_dists))
    for package_nevra in builder.get_package_nevra(spec_nvr, package_dists):
        info = builder.mysession.getBuild(package_nevra)
        if info:
            download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra))
        else:
            build_list.append((spec, builder.get_dist_from_koji_build_name(package_nevra)))

# Sort the list by platform so it is easier to spot missing things in the output
download_list = sorted(download_list, key=lambda download: download[1])

# Perform a scratch build of all the unbuilt packages
build_ids = []
Exemple #5
0
# Check for external deps
# for component in get_components(configuration):
#     external_deps_file = component.get('external_deps')
#     if external_deps_file:
#         external_deps_file = os.path.join(working_dir, component.get('name'), external_deps_file)
#         for package_nevra in builder.get_build_names_from_external_deps_file(external_deps_file):
#             info = builder.mysession.getBuild(package_nevra)
#             if info:
#                 download_list.extend(builder.get_urls_for_build(builder.mysession, package_nevra, rpmsig=rpm_signature))
#             else:
#                 print "External deps requires %s but it could not be found in koji" % package_nevra
#                 sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(os.path.join(working_dir,
                                                     opts.project)):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec)
    print "%s %s" % (spec_nvr, package_dists)
    for package_nevra in builder.get_package_nevra(spec_nvr, package_dists):
        info = builder.mysession.getBuild(package_nevra)
        if info:
            download_list.extend(
                builder.get_urls_for_build(builder.mysession, package_nevra))
        else:
            build_list.append(
                (spec, builder.get_dist_from_koji_build_name(package_nevra)))

# Sort the list by platform so it is easier to spot missing things in the output
download_list = sorted(download_list, key=lambda download: download[1])
for component in builder.components(configuration):
    external_deps_file = component.get('external_deps')
    if external_deps_file:
        external_deps_file = os.path.join(WORKING_DIR, component.get('name'), external_deps_file)
        for package_nevra in builder.get_build_names_from_external_deps_file(
                external_deps_file, include_unsupported=opts.build_unsupported):
            info = builder.mysession.getBuild(package_nevra)
            if info:
                download_list.extend(builder.get_urls_for_build(
                    builder.mysession, package_nevra, rpmsig=rpm_signature))
            else:
                print("External deps requires %s but it could not be found in koji" % package_nevra)
                sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(WORKING_DIR):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(spec, include_unsupported=opts.build_unsupported)

    # Per our support policy:
    # - ensure the dists list include el5 and el6 for platform, puppet, and rpm
    # - always exclude el5 for other plugins
    # - exclude el6 for plugins when platform version > 2.12 and not building unsupported packages
    if os.path.basename(spec) in unsupported_specs.values():
        if 'el6' not in package_dists:
            package_dists = ['el6'] + package_dists
        if 'el5' not in package_dists:
            package_dists = ['el5'] + package_dists
    elif not opts.build_unsupported:
        if 'el5' in package_dists:
            package_dists.remove('el5')
Exemple #7
0
                external_deps_file,
                include_unsupported=opts.build_unsupported):
            info = builder.mysession.getBuild(package_nevra)
            if info:
                download_list.extend(
                    builder.get_urls_for_build(builder.mysession,
                                               package_nevra,
                                               rpmsig=rpm_signature))
            else:
                print(
                    "External deps requires %s but it could not be found in koji"
                    % package_nevra)
                sys.exit(1)

# Get all spec files
for spec in builder.find_all_spec_files(WORKING_DIR):
    spec_nvr = builder.get_package_nvr_from_spec(spec)
    package_dists = builder.get_dists_for_spec(
        spec, include_unsupported=opts.build_unsupported)

    # Per our support policy:
    # - ensure the dists list include el5 and el6 for platform
    # - always exclude el5 for plugins
    # - exclude el6 for plugins when platform version > 2.12 and not building unsupported packages
    if os.path.basename(spec) == 'pulp.spec':
        if 'el6' not in package_dists:
            package_dists = ['el6'] + package_dists
        if 'el5' not in package_dists:
            package_dists = ['el5'] + package_dists
    elif not opts.build_unsupported:
        if 'el5' in package_dists: