diff --git a/defaults/main.yml b/defaults/main.yml index 1df3936a..41f2e157 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -173,7 +173,7 @@ lxc_cache_prep_post_commands: '## post command skipped ##' # or by providing the full path to a local file containing all of the variables # needed to prepare a container. built-in supported values are: # [redhat-7.yml, suse-42.yml, ubuntu-16.04.yml, ubuntu-18.04.yml] -lxc_user_defined_container: null +#lxc_user_defined_container: null # Full path to the base image prep script. By default this will use the # named script for a given OS within the "templates/prep-scripts" directory. diff --git a/tasks/main.yml b/tasks/main.yml index a8329391..95179ac5 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -45,7 +45,7 @@ - name: Gather container variables include_vars: "{{ item }}" with_first_found: - - "{{ lxc_user_defined_container }}" + - "{{ lxc_user_defined_container | default([]) }}" - "{{ ansible_distribution | lower }}-{{ ansible_distribution_version | lower }}.yml" - "{{ ansible_distribution | lower }}-{{ ansible_distribution_major_version | lower }}.yml" - "{{ ansible_os_family | lower }}-{{ ansible_distribution_major_version | lower }}.yml"