From 9a1dce56199da8d0ad4e7291287fdec102eb49b5 Mon Sep 17 00:00:00 2001 From: "Brian C. Lane" Date: Thu, 10 May 2018 08:51:53 -0700 Subject: [PATCH] Set lorax_templates to the correct directory Templates are under the share dir, so use find_templates() to find them. --- src/pylorax/api/queue.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/pylorax/api/queue.py b/src/pylorax/api/queue.py index 1cdf8202..993ff32e 100644 --- a/src/pylorax/api/queue.py +++ b/src/pylorax/api/queue.py @@ -28,6 +28,7 @@ import subprocess from subprocess import Popen, PIPE import time +from pylorax import find_templates from pylorax.api.compose import move_compose_results from pylorax.api.recipes import recipe_from_file from pylorax.base import DataHolder @@ -168,10 +169,13 @@ def make_compose(cfg, results_dir): cfg_dict["armplatform"] = "" cfg_dict["squashfs_args"] = None - cfg_dict["lorax_templates"] = cfg.share_dir + cfg_dict["lorax_templates"] = find_templates(cfg.share_dir) cfg_dict["tmp"] = "/var/tmp/" cfg_dict["dracut_args"] = None # Use default args for dracut + # TODO How to support other arches? + cfg_dict["arch"] = None + # Compose things in a temporary directory inside the results directory cfg_dict["result_dir"] = joinpaths(results_dir, "compose") os.makedirs(cfg_dict["result_dir"])