Added package installed for FreeBSD

This commit is contained in:
Greg Ballantine 2017-10-30 13:23:16 -04:00
parent b818eb706b
commit 378229a359
3 changed files with 12 additions and 1 deletions

View File

@ -1,4 +1,6 @@
nsswitch:
package_name: False
config_path: /etc/nsswitch.conf
config_mode: '0644'

View File

@ -1,5 +1,13 @@
{% from "nsswitch/map.jinja" import nsswitch_settings as nsswitch with context %}
{% if nsswitch.package_name %}
nsswitch_package:
pkg.installed:
- name: {{ nsswitch.package_name }}
- require_in:
- file: nsswitch_config
{% endif %}
nsswitch_config:
file.managed:
- name: {{ nsswitch.config_path }}

View File

@ -14,7 +14,8 @@ that differ from whats in defaults.yaml
'config_path': '/etc/nsswitch.conf',
},
'FreeBSD': {
'config_path': '/etc/nsswitch.conf',
'package_name': 'nss'
'config_path': '/usr/local/etc/nsswitch.conf',
},
'RedHat': {
'config_path': '/etc/nsswitch.conf',