Use empty env variable set if missing

When a set of global_environment_variables is not provided, Ansible
throws a warning:

  [WARNING]: could not parse environment value, skipping:
  [u'{{deployment_environment_variables | default({}) }}',
  u'{{global_environment_variables | default(omit) }}']

This patch returns an empty dict rather than using the omit filter.

Change-Id: I5e3399b816779821e936b84a2972ca1db39c1a62
This commit is contained in:
Major Hayden 2017-10-10 14:24:48 -05:00
parent 427be7bb2d
commit e34eee48ea
No known key found for this signature in database
GPG Key ID: 737051E0C1011FB1
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@
- name: Clone git repositories asynchronously
become: yes
become_user: "{{ repo_build_service_user_name }}"
environment: "{{ global_environment_variables | default(omit) }}"
environment: "{{ global_environment_variables | default({}) }}"
git:
repo: "{{ item['url'] }}"
dest: "{{ repo_build_git_dir }}/{{ item['name'] }}"