Compare commits

...

43 Commits

Author SHA1 Message Date
Patrick McCarty b44cd8c2c6 Release v1.15
This release adds support for using DNF on Clear Linux.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-02-13 15:22:29 -08:00
Patrick McCarty 8468405d9a Add support for DNF on Clear Linux
DNF enablement was completed in Clear Linux builds > 20650, so
autodetect whether yum or DNF should be used for chroot creation when
running on Clear Linux.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-02-13 11:43:59 -08:00
Tudor Marcu 2024792039 Release v1.14
Suppress extra yum plugin output.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2018-02-01 11:24:56 -08:00
George T Kramer 4afdbd6c8e Filter yum output for parsing with yum plugins
Dependeing if plugins are enabled when yum is directed to honor plugin
usage, the output from yum list changes, and has the potential to break
the creation of the versions file.  Suppressing this additional plugin
output by operating yum in quiet mode avoids this risk.

Signed-off-by: George T Kramer <george.t.kramer@intel.com>
2018-02-01 11:19:01 -08:00
Tudor Marcu 2f17b8187e Release v1.13
This release enables yum plugin usage in bundle-chroot-builder.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2018-01-17 13:53:49 -08:00
George T Kramer df44fd82f0 Allow yum plugin usage
When doing a yum install, plugins should be able to modify how this
operation is performed.  Allowing the use of a priority plugin, or a
fastest mirror plugin, or other possibly useful plugins would be up to
the user and dependent on the yum configuration they use for building
the chroot for their bundles.

Signed-off-by: George T Kramer <george.t.kramer@intel.com>
2018-01-17 13:45:37 -08:00
Tudor Marcu 2b92b2eff2 Release v1.12
This release enables using environment variables in the builder.conf,
and adds a README for making/installing the program.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2018-01-04 11:44:55 -08:00
Mark Horn e6e3bab777 Added basic build instructions
Add the basic steps for building and installing this project.

Signed-off-by: Mark Horn <mark.d.horn@intel.com>
2018-01-04 10:15:43 -08:00
Mark Horn ff6a30cc43 Enable Environment Variables in Configuration File
This code change enables the use of Linux Environment
variables in the configuration file. This is very useful
for paths to avoid having to hard-code paths.

Added error checking on the environment variables.

For proper use, it will also require a similar patch to
the mixer-tools project.

Signed-off-by: Mark Horn <mark.d.horn@intel.com>
2018-01-02 09:47:13 -08:00
Matthew Johnson 798b4e8906 Release v1.11
This release adds a configuration section for debuginfo banning in the
swupd-server configuration file server.ini.

Signed-off-by: Matthew Johnson <matthew.johnson@intel.com>
2017-09-20 14:56:14 -07:00
Matthew Johnson 6a0cafa617 Add debuginfo configuration for server.ini
Add configuration for debuginfo bans to server.ini via builder.conf.
These configurations will be directly used by swupd-server to determine
if it should ban debuginfo files from the manifests and exactly which
paths should be banned. This patch cleans up the writing of the
server.ini file as well.

Signed-off-by: Matthew Johnson <matthew.johnson@intel.com>
2017-09-19 10:33:16 -07:00
Tudor Marcu 1bb15ab253 Release v1.10
This release fixes the builder.conf template to match what is shown in
the documentation page.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-08-08 11:12:14 -07:00
Tudor Marcu 02f5c8fad9 Update builder.conf
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-08-08 11:03:30 -07:00
Patrick McCarty 579f606714 Merge tag 'v1.09' 2017-04-04 13:24:07 -07:00
Tudor Marcu 537bacec41 Release v1.09
Properly handle m4 errors during build process.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-04-04 12:33:12 -07:00
Tudor Marcu cd634c88df Release v1.09
Properly handle m4 errors during build process.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-04-04 12:29:27 -07:00
Tudor Marcu 0e50054fa1 Exit on m4 error
M4 may fail here in the case of circular includes, causing the updater
to crash later. This patch checks that the subprocess call succeeded, and if not
raises an exception to exit. It may not terminate instantly due to the async
nature of processing bundles, but once the bad thread finishes it will exit.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-03-22 16:19:04 -07:00
Tudor Marcu 6aa46648d0 Exit on m4 error
M4 may fail here in the case of circular includes, causing the updater
to crash later. This patch checks that the subprocess call succeeded, and if not
raises an exception to exit. It may not terminate instantly due to the async
nature of processing bundles, but once the bad thread finishes it will exit.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2017-03-22 15:45:16 -07:00
Patrick McCarty bcffbb7096 Exclude empty subpackages from the SRPM file lists
The string "(contains no files)" is printed when running 'rpm -ql ...'
for an empty subpackage. Since that output is more useful for
interactive use, make sure the string is excluded from the final SRPM
file lists that begin with files-*.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2017-01-24 16:10:28 -08:00
Tudor Marcu 9fc98a03b1 Release v1.08
This release fixes the builder.conf template so it has a more sane starting
point.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-11-09 12:13:35 -08:00
Tudor Marcu c96046001e Fix builder.conf template
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-11-09 12:13:14 -08:00
Tudor Marcu 0d0e64e2a9 Release v1.07
This release updates bundle-chroot-builder to support the new mixer-tools and
builder.conf format.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-11-04 17:56:58 -07:00
Tudor Marcu be05f6b513 Default to outputting content in the mixer workspace
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-10-28 13:09:03 -07:00
Tudor Marcu d07ac01932 Update builder.conf to match docs and new tooling
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-10-28 12:18:09 -07:00
Tudor Marcu 82bd4409f8 Version numbers are now read from builder.conf
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-10-28 11:55:35 -07:00
Tudor Marcu 78e419ee2c Print out which builder.conf is being used
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-10-27 12:13:13 -07:00
Tudor Marcu 9d987f5e3b Release v1.06
This release moves the noship folder to the chroot location, because chroot
builder should not be adding any content to the webdir, and renames the
latest.version file to more appropriately match its use.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-09-29 10:39:06 -07:00
Tudor Marcu 629f940676 Change version file to more appropriate name
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-09-29 10:35:54 -07:00
Tudor Marcu 68084ca1b6 Move noship dir to image instead of www
This is an artifict needed by the swupd-server when creating update content
in the webdir, it should not exist in the webdir since it is being created
as part of the chroot building process. All content produced by the chroot
builder should live in the STATE_DIR/image/VER directory.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-09-29 10:35:26 -07:00
Tudor Marcu 4225b901a9 Release v1.05
This release changes the builder to read raw bytes to account for weirdly
encoded filenames, and provides better output to the user.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-09-26 11:56:00 -07:00
Patrick McCarty dee894f28d Add progress messages for builder.conf values
To help debug issues related to SWUPD config values being set in the
chroot, or not, print out diagnostic messages to display the expected
values.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2016-09-06 11:39:05 -07:00
Tudor Marcu 9919c1523f Use raw bytes to read filenames
We cannot be sure of the encoding used for certain filenames or the locale on
a specific system, so use raw bytes and don't worry about the encoding of the
filenames.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-08-31 15:56:06 -07:00
Tudor Marcu bda3519d4d Release v1.04
This release introduces functionality to blacklist/ignore bundles beginning with
a '.', and will support other banned characters in the future.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-05-03 20:26:44 +00:00
Tudor Marcu a1c4e4a5c5 Do not accept bundles beginning with '.'
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-05-03 20:26:01 +00:00
Brad T. Peters 58ddb254dc Release v1.03
This release patches a bug where whitespace was not being
correctly stripped from package names

Signed-off-by: Brad T. Peters <brad.t.peters@intel.com>
2016-04-12 13:58:56 -07:00
Brad T. Peters 18620f4efb Fix whitespace issue with pkg name
Preceeding or trailing whitespaces must be stripped

Signed-off-by: Brad T. Peters <brad.t.peters@intel.com>
2016-04-12 13:54:59 -07:00
Tudor Marcu efaa5b9051 Release v1.02
This release includes fixes for validating builder.conf is correct, and fixes a
bug where the chroot builder would loop forever if m4 output was too large.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-29 11:54:08 -07:00
Tudor Marcu d5d8692156 Remove URL option as content & version are enough
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-28 14:16:54 -07:00
Tudor Marcu ef79a9ce59 Fix m4 infinite wait()
If there are a lot of packages then the m4 output will overflow the max
PIPE buffer, and the wait() will never finish. This patch reads the output
in chunks and then creates a string of the entire output to pass to yum.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-28 14:09:50 -07:00
Tudor Marcu 2d1f4a75cd Make sure builder.conf is filled correctly
Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-25 17:02:51 -07:00
Tudor Marcu 24d8b59fdf Remove leading slash in os.path.join()
The os.path.join() function discard any previos paths/variables when it
encounters one starting with a leading "/" so the statedir & bundle name were
completely ignored when it ran into /usr/share/defaults/...
This fixes it so the path is correctly made, and the dirs and files should be
installed correctly.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-25 13:08:32 -07:00
tmarcu 4cdc1ea888 Merge pull request #2 from clearlinux/url_confs
Add url for swupd in builder.conf
2016-03-24 17:01:23 -07:00
Tudor Marcu e14a928b37 Add url for swupd in builder.conf
The update client currently defaults to the public clearlinux url, and must be
overridden with cmd line options to use other version/content/format urls. This
introduces a problem when running a mix, and not supplying the mix URL will
cause swupd to update from the official URL, rather than the mixer url.
With this patch, the URLs can all be specified and are inserted into conf files
that the swupd client will read, to know what URL to default to.

Signed-off-by: Tudor Marcu <tudor.marcu@intel.com>
2016-03-24 16:42:36 -07:00
4 changed files with 180 additions and 32 deletions
+20
View File
@@ -1,3 +1,23 @@
Building this Project
=====================
For help using automake see
http://www.gnu.org/software/automake/manual/html_node/index.html
Configure:
aclocal
autoconf
automake --add-missing
# Defaults to /usr/local or specific --prefix=/usr
# to overwrite the installed version
./configure
Build:
make
Install:
make -n install
sudo make install
Configuration File
==================
Please update the configuration file paths to point to where your
+16 -3
View File
@@ -1,4 +1,17 @@
[Builder]
SERVER_STATE_DIR = /var/lib/update
BUNDLE_DIR = /home/clr/mix/bundles
YUM_CONF = /usr/share/defaults/bundle-chroot-builder/yum.conf
SERVER_STATE_DIR=/home/clr/mix/update
BUNDLE_DIR=/home/clr/mix/mix-bundles
YUM_CONF=/home/clr/mix/.yum-mix.conf
CERT=/home/clr/mix/Swupd_Root.pem
VERSIONS_PATH=/home/clr/mix
[swupd]
BUNDLE=os-core-update
CONTENTURL=<URL where the content will be hosted>
VERSIONURL=<URL where the version of the mix will be hosted>
FORMAT=1
[Server]
debuginfo_banned=true
debuginfo_lib=/usr/lib/debug/
debuginfo_src=/usr/src/debug/
+143 -28
View File
@@ -25,6 +25,7 @@ import argparse
import configparser
import os
import os.path
import io
import platform
import re
import shutil
@@ -47,14 +48,36 @@ def handle_options():
return args
def read_config(args):
def get_config(args):
buildconf='/usr/share/defaults/bundle-chroot-builder/builder.conf'
if os.path.isfile('/etc/bundle-chroot-builder/builder.conf'):
buildconf = '/etc/bundle-chroot-builder/builder.conf'
if args.config:
buildconf = args.config
print("Reading from %s" % buildconf)
cfg_txt = ""
# Check that the environment variables in the config file are valid
pattern = re.compile("\$\{?(\w+)\}?")
for i, line in enumerate(open(buildconf, 'r')):
for match in re.finditer(pattern, line):
if not match.group(1) in os.environ:
print("ERROR:\nbuilder.conf contains an undefined environment variable: %s on line %s\n"
% (i+1, match.group(1)))
exit(1)
cfg_txt += os.path.expandvars(line)
config = configparser.ConfigParser()
config.read(buildconf)
config.readfp(io.StringIO(cfg_txt))
return config
def read_config(args):
config = get_config(args)
for option in ['SERVER_STATE_DIR', 'BUNDLE_DIR', 'YUM_CONF']:
if config.has_option('Builder', option) == False:
print("ERROR:\nbuilder.conf is missing:\n[Builder]\n%s\n" % option)
exit(1)
"""Read the configuration file for our script values"""
conf = config['Builder']
@@ -67,12 +90,19 @@ def read_config(args):
def install_bundle(out_dir, postfix, bundle, bundles, yum_cmd):
"""Helper function to yum install a bundle"""
m4 = subprocess.Popen(["m4", bundles + "/" + bundle], cwd=bundles, stdout=subprocess.PIPE)
m4.wait()
pkgs = m4.stdout.readlines()
lines = []
try:
output = subprocess.check_output(["m4", bundles + "/" + bundle], cwd=bundles, bufsize=1, universal_newlines=True)
except subprocess.CalledProcessError as e:
print('ERROR {0}: m4 failed on {1}/{2}'.format(e.returncode, bundles, bundle))
raise
for line in output:
lines.append(line)
pkgs = "".join(lines)
to_install = []
for pkg in pkgs:
pkg = pkg.decode("utf-8").strip()
for pkg in pkgs.splitlines():
pkg = pkg.strip()
# Don't add blank lines or lines with leading '#'
if len(pkg) == 0 or pkg[0] == "#":
continue
@@ -138,6 +168,37 @@ def clean_bundle(out_dir, bundle, bundles, yum_cmd):
os.chdir(prev_dir)
def write_default_server_ini(state_dir, server_conf):
"""
Write default server.ini file in the state dir in the following format
[Server]
emptydir={state_dir}/empty/
imagebase={state_dir}/image/
outputdir={state_dir}/www/
[Debuginfo]
banned=true
lib=/usr/lib/debug/
src=/usr/src/debug/
"""
contents = ("[Server]\n"
"emptydir={0}/empty/\n"
"imagebase={0}/image/\n"
"outputdir={0}/www/\n".format(state_dir))
if server_conf:
contents += ("\n[Debuginfo]\n"
"banned={}\n"
"lib={}\n"
"src={}\n"
.format(server_conf.get('debuginfo_banned'),
server_conf.get('debuginfo_lib'),
server_conf.get('debuginfo_src')))
with open(state_dir + "/server.ini", "w+") as serverini:
serverini.write(contents)
def create_chroots(args, state_dir, bundles, yum_conf):
"""The state_dir should always be created if it does not exist"""
if os.path.isdir(state_dir) == False:
@@ -151,12 +212,15 @@ def create_chroots(args, state_dir, bundles, yum_conf):
if os.path.isdir(state_dir + "/www/0") == False:
os.makedirs(state_dir + "/www/0")
"""Create server.ini and groups.ini for create_update later on"""
with open(state_dir + "/server.ini", "w+") as serverini:
serverini.write("[Server]\nemptydir=" + state_dir + "/empty/\nimagebase=" + state_dir + "/image/\noutputdir=" + state_dir + "/www/\n")
# Create server.ini and groups.ini for create_update later on
config = get_config(args)
config = config['Server'] if 'Server' in config else {}
write_default_server_ini(state_dir, config)
with open(state_dir + "/groups.ini", "w+") as groupsini:
for bundle in os.listdir(bundles):
groupsini.write("[" + bundle + "]\ngroup=" + bundle + "\n\n")
bundle_list = os.listdir(bundles)
bundle_list = trim_bundles(bundle_list)
for bundle in bundle_list:
groupsini.write("[{0}]\ngroup={0}\n\n".format(bundle))
"""Setup chroots for bundles"""
bversion = ""
@@ -167,8 +231,8 @@ def create_chroots(args, state_dir, bundles, yum_conf):
out_version = args.version
build_version = args.version
if os.path.exists(state_dir + "/image/latest.version") == False:
with open(state_dir + "/image/latest.version", "w") as latestver:
if os.path.exists(state_dir + "/image/LAST_VER") == False:
with open(state_dir + "/image/LAST_VER", "w") as latestver:
latestver.write("0\n")
config = configparser.ConfigParser()
@@ -185,12 +249,21 @@ def create_chroots(args, state_dir, bundles, yum_conf):
out_dir = state_dir + "/image/" + out_version
if platform.dist()[0] == "fedora" and int(platform.dist()[1]) >= 22:
try:
with open("/usr/share/clear/version", "r") as verfile:
clrver = int(verfile.read().strip())
except Exception:
clrver = None
if clrver and clrver > 20650:
print("using dnf on clr")
packager = ["dnf"]
elif platform.dist()[0] == "fedora" and int(platform.dist()[1]) >= 22:
print("using dnf instead of yum")
packager = ["dnf"]
else:
packager = ["yum"]
yum_cmd = packager + ["--config={}".format(yum_conf), "-y", "--noplugins", "--releasever={}".format(build_version)]
yum_cmd = packager + ["--config={}".format(yum_conf), "-y", "--releasever={}".format(build_version)]
if 'local' in config == False:
try:
urllib.request.urlopen(conf_baseurl)
@@ -236,7 +309,7 @@ def create_chroots(args, state_dir, bundles, yum_conf):
print("Noting os-core package list")
with open(out_dir + "/versions", "w") as file:
subprocess.Popen(yum_cmd + ["--installroot={}/os-core".format(out_dir), "list"], stdout=file).wait()
subprocess.Popen(yum_cmd + ["--quiet", "--installroot={}/os-core".format(out_dir), "list"], stdout=file).wait()
with open(out_dir + "/packages-os-core", "w") as file:
subprocess.Popen(['rpm', '--root={}/os-core'.format(out_dir),
'-qa', '--queryformat', '%{NAME}\t%{SOURCERPM}\n'], stdout=file).wait()
@@ -253,6 +326,7 @@ def create_chroots(args, state_dir, bundles, yum_conf):
bundle_list = os.listdir(bundles)
bundle_list.remove('os-core')
bundle_list = trim_bundles(bundle_list)
pool = multiprocessing.Pool()
results_list = []
@@ -271,6 +345,34 @@ def create_chroots(args, state_dir, bundles, yum_conf):
for r in results_list:
r.get()
"""Read the URL values from builder.conf and insert them into os-core-update to swupd knows where to pull content from"""
config = get_config(args)
"""Read the configuration file for our script values"""
for option in ['BUNDLE', 'CONTENTURL', 'VERSIONURL', 'FORMAT']:
if config.has_option('swupd', option) == False:
print("ERROR:\nbuilder.conf is missing:\n[swupd]\n%s\n" % option)
exit(1)
conf = config['swupd']
bundlename = conf['BUNDLE']
contenturl = conf['CONTENTURL']
versionurl = conf['VERSIONURL']
formatname = conf['FORMAT']
print("Adding SWUPD default values to '{}' bundle...".format(bundlename))
"""Do not add a leading slash on anything except the first variable in os.path.join!"""
confpath = os.path.join(out_dir, bundlename, "usr/share/defaults/swupd/")
os.makedirs(confpath, exist_ok=True)
with open(os.path.join(confpath, "contenturl"), "w") as file:
file.writelines(contenturl)
print(" contenturl: {}".format(contenturl))
with open(os.path.join(confpath, "versionurl"), "w") as file:
file.writelines(versionurl)
print(" versionurl: {}".format(versionurl))
with open(os.path.join(confpath, "format"), "w") as file:
file.writelines(formatname)
print(" format: {}".format(formatname))
print("Creating package to file mappings")
package_mapping = {}
map_files = [f for f in os.listdir(out_dir) if f.startswith("pkgmap-")]
@@ -280,14 +382,18 @@ def create_chroots(args, state_dir, bundles, yum_conf):
# real package's filename I'm using it instead of recursing through
# temporary per bundle folders
package_name = map_file[map_file.find(" * ") + 3:-len(".src.rpm")]
with open(out_dir + "/" + map_file, "r") as file:
with open(out_dir + "/" + map_file, "rb") as file:
path_list = file.readlines()
if package_name not in package_mapping:
package_mapping[package_name] = set()
for path in path_list:
# RPM prints out a specific string for subpackages that contain no
# files. It should be excluded from the SRPM file list.
if re.match(br"\(contains no files\)\n", path):
continue
package_mapping[package_name].add(path)
for package_name, paths in package_mapping.items():
with open(out_dir + "/files-{}".format(package_name), "w") as file:
with open(out_dir + "/files-{}".format(package_name), "wb") as file:
file.writelines(sorted(paths))
for map_file in map_files:
os.unlink(out_dir + "/" + map_file)
@@ -297,16 +403,17 @@ def create_chroots(args, state_dir, bundles, yum_conf):
print("Cleaning package list")
web_dir = state_dir + "/www/" + out_version + "/"
image_dir = state_dir + "/image/" + out_version + "/"
if os.path.isdir(web_dir):
print(" removing pre-existing {} before setting version file" .format(web_dir))
os.system('rm -rf '+web_dir)
# FIXME: Figure out problems with the below to replace the above.
# Consider all uses of os.system("rm -fr") as FIXMEs of the same variety.
# if os.path.isdir(web_dir):
# if os.path.isdir(image_dir):
# print(" removing pre-existing {} before setting version file"
# .format(web_dir))
# shutil.rmtree(web_dir)
os.makedirs(web_dir + '/noship')
# .format(imagedir())
# shutil.rmtree(image_dir)
os.makedirs(image_dir + '/noship')
versions_output = []
with open(out_dir + "/versions", "r") as file:
versions = set()
@@ -324,16 +431,24 @@ def create_chroots(args, state_dir, bundles, yum_conf):
versions_output.append("{0: <50}{1}\n".format("Available", "Packages"))
for name, pver in [line.split(":") for line in versions]:
versions_output.append("{0: <50}{1}\n".format(name, pver))
with open(web_dir + "versions", "w") as file:
with open(image_dir + "versions", "w") as file:
file.writelines(versions_output)
for bundle in os.listdir(bundles):
shutil.copyfile(out_dir + "/packages-{}".format(bundle), web_dir + "/noship/packages-{}".format(bundle))
bundle_list = os.listdir(bundles)
bundle_list = trim_bundles(bundle_list)
for bundle in bundle_list:
shutil.copyfile(out_dir + "/packages-{}".format(bundle), image_dir + "/noship/packages-{}".format(bundle))
if os.path.isfile(out_dir + "/{}-includes".format(bundle)):
shutil.copyfile(out_dir + "/{}-includes".format(bundle), web_dir + "/noship/{}-includes".format(bundle))
shutil.copyfile(out_dir + "/{}-includes".format(bundle), image_dir + "/noship/{}-includes".format(bundle))
for package_name in package_mapping.keys():
shutil.copyfile(out_dir + "/files-{}".format(package_name),
web_dir + "/noship/files-{}".format(package_name))
image_dir + "/noship/files-{}".format(package_name))
# Remove bundles with blacklisted characters, such as dot files
def trim_bundles(bundles):
for bundle in bundles:
if bundle.startswith('.'):
bundles.remove(bundle)
return bundles
def main():
"""Entry point for chroot creator"""
+1 -1
View File
@@ -1,5 +1,5 @@
AC_PREREQ([2.68])
AC_INIT([bundle-chroot-builder],[1.00],[tudor.marcu@intel.com],[bundle-chroot-builder])
AC_INIT([bundle-chroot-builder],[1.15],[tudor.marcu@intel.com],[bundle-chroot-builder])
AM_INIT_AUTOMAKE([foreign silent-rules color-tests no-dist-gzip dist-xz])
AC_CONFIG_FILES(Makefile)
AC_PREFIX_DEFAULT(/usr/local)