Parcourir la source

Adding support for the enforce_password option.

This will allow users change their passwords after the initial setting in Salt.
lookup-fix-3
Seth Miller il y a 9 ans
Parent
révision
7dca1ebfd2
2 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. +1
    -0
      pillar.example
  2. +3
    -0
      users/init.sls

+ 1
- 0
pillar.example Voir le fichier

buser: buser:
fullname: B User fullname: B User
password: $6$w............. password: $6$w.............
enforce_password: True
home: /custom/buser home: /custom/buser
createhome: True createhome: True
manage_vimrc: False manage_vimrc: False

+ 3
- 0
users/init.sls Voir le fichier

{% if 'password' in user -%} {% if 'password' in user -%}
- password: '{{ user['password'] }}' - password: '{{ user['password'] }}'
{% endif -%} {% endif -%}
{% if 'enforce_password' in user -%}
- enforce_password: '{{ user['enforce_password'] }}'
{% endif -%}
{% if user.get('system', False) -%} {% if user.get('system', False) -%}
- system: True - system: True
{% endif -%} {% endif -%}

Chargement…
Annuler
Enregistrer