Skip to content

Instantly share code, notes, and snippets.

@gordonm
Forked from trane/gist:2033125
Created March 14, 2012 01:54
Show Gist options
  • Save gordonm/2033330 to your computer and use it in GitHub Desktop.
Save gordonm/2033330 to your computer and use it in GitHub Desktop.
[ david@samwise ] $ cat salt.sls
/etc/salt/minion:
file:
- managed
- owner: root
- group: root
- mode: 444
- source: salt://salt/files/salt-minion.config
- template: jinja
- context:
{% if grains['fqdn'] == 'samwise.foo.bar'%}
modules_dirs: ['/home/core/modules', '/opt/salt/modules']
{% else %}
modules_dirs: ['/opt/salt/modules']
{% endif %}
[ david@samwise ] $ cat salt-minion.config
master: localhost
modules_dirs: {{ modules_dirs }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment