diff --git a/states/samba/config.sls b/states/samba/config.sls index d0c3d81..2f44ebf 100644 --- a/states/samba/config.sls +++ b/states/samba/config.sls @@ -3,4 +3,4 @@ samba-config: ini_manage.options_present: - name: /etc/samba/smb.conf - - sections: {{ samba.config }} + - sections: {{ samba.config }} diff --git a/states/samba/defaults.yaml b/states/samba/defaults.yaml index 38d17e5..167f71d 100644 --- a/states/samba/defaults.yaml +++ b/states/samba/defaults.yaml @@ -1,4 +1,6 @@ --- samba: enabled: true - config: {} + config: + global: + workgroup: PAULBSD diff --git a/states/samba/users.sls b/states/samba/users.sls index 929375e..c5c5108 100644 --- a/states/samba/users.sls +++ b/states/samba/users.sls @@ -6,13 +6,14 @@ samba-user-{{ user.name }}: {%- if user.enabled %} pdbedit.managed: -{%- else %} - pdbedit.absent: -{%- endif %} - name: {{ user.name }} - login: {{ user.name }} - password: "{{ user.password }}" - password_hashed: false +{%- else %} + pdbedit.absent: + - name: {{ user.name }} +{%- endif %} - require: - pkg: samba-pkg {%- endfor %}