diff --git a/plugins/builder/osbuild.py b/plugins/builder/osbuild.py index a3090a5..e64cdf6 100644 --- a/plugins/builder/osbuild.py +++ b/plugins/builder/osbuild.py @@ -267,9 +267,8 @@ class OSBuildImage(BaseTaskHandler): return [Repository(repourl + "/$arch")] def make_repos_for_user(self, repos): - urls = repos.split(',') - self.logger.debug("user repo override: %s", urls) - return [Repository(u.strip()) for u in urls] + self.logger.debug("user repo override: %s", str(repos)) + return [Repository(r) for r in repos] # pylint: disable=arguments-differ def handler(self, name, version, distro, image_types, target, arches, opts): diff --git a/plugins/cli/osbuild.py b/plugins/cli/osbuild.py index 3eb497c..0a05e1c 100755 --- a/plugins/cli/osbuild.py +++ b/plugins/cli/osbuild.py @@ -76,7 +76,7 @@ def handle_osbuild_image(options, session, argv): opts["release"] = args.release if args.repo: - opts["repo"] = ",".join(args.repo) + opts["repo"] = args.repo # Do some early checks to be able to give quick feedback check_target(session, target) diff --git a/plugins/hub/osbuild.py b/plugins/hub/osbuild.py index 90e8177..a024b9f 100644 --- a/plugins/hub/osbuild.py +++ b/plugins/hub/osbuild.py @@ -52,8 +52,11 @@ OSBUILD_IMAGE_SCHEMA = { "additionalProperties": False, "properties": { "repo": { - "type": "string", - "description": "Repositories" + "type": "array", + "description": "Repositories", + "items": { + "type": "string" + } }, "release": { "type": "string", diff --git a/test/unit/test_builder.py b/test/unit/test_builder.py index a235beb..04e4ebb 100644 --- a/test/unit/test_builder.py +++ b/test/unit/test_builder.py @@ -338,7 +338,7 @@ class TestBuilderPlugin(PluginTest): ["image_type"], "fedora-candidate", ["x86_64"], - {"repo": ",".join(repos)}] + {"repo": repos}] url = self.plugin.DEFAULT_COMPOSER_URL composer = MockComposer(url, architectures=["x86_64"])