fix: Encapsulate module echo in quotes to be passed in as a single arg

This commit is contained in:
Gerald Pinder 2023-10-27 17:43:05 -04:00
parent b1b2b0b2ac
commit f2ab9bfd4a

View file

@ -37,7 +37,7 @@ ARG BASE_IMAGE="{{ base_image }}"
{% macro run_modules(module) %}
{% if module.type %}
RUN chmod +x /tmp/modules/{{ module.type }}/{{ module.type }}.sh
RUN source /tmp/exports.sh && OS_VERSION="$(grep -Po '(?<=VERSION_ID=)\d+' /usr/lib/os-release)" /tmp/modules/{{ module.type }}/{{ module.type }}.sh $(echo -e "{{ print_module_context(module = module) }}")
RUN set -x && source /tmp/exports.sh && OS_VERSION="$(grep -Po '(?<=VERSION_ID=)\d+' /usr/lib/os-release)" /tmp/modules/{{ module.type }}/{{ module.type }}.sh "$(echo -e "{{ print_module_context(module = module) }}")"
{% elif module["from-file"] %}
{% set extra_module = get_module_from_file(file = module["from-file"]) %}
{% for m in extra_module.modules %}