From 868854c2e730c5a1ff22f9e98653890708e01fd6 Mon Sep 17 00:00:00 2001 From: Marvin Frick Date: Sun, 9 Nov 2014 13:16:06 +0100 Subject: [PATCH] enables use of jinja < 2.6 Commit 2b51a6f0c39b4df56823afe9d114dab886e3359e introduced options for gitfs_remotes in a pillar by using a jinja test to see if a parameter is a mapping (dict etc.). This feature however is only available in jinja 2.6 or newer (see http://jinja.pocoo.org/docs/dev/templates/#mapping). Although this version of Jinja is available on Ubuntu, other OS / package managers do provide older versions (2.2.1 in RedHat 6). This change makes use of the "iterable" test which should do the exact same thing. --- salt/files/master.d/_defaults.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/salt/files/master.d/_defaults.conf b/salt/files/master.d/_defaults.conf index b08292efa..e56e21695 100644 --- a/salt/files/master.d/_defaults.conf +++ b/salt/files/master.d/_defaults.conf @@ -484,7 +484,7 @@ fileserver_backend: {% if 'gitfs_remotes' in master -%} gitfs_remotes: {%- for remote in master['gitfs_remotes'] %} -{% if remote is mapping %} +{% if remote is iterable %} {%- for repo, children in remote.iteritems() -%} - {{ repo }}: {%- for child in children %}