saltstack-formulas / maven-formula

A minimalistic way to install just the maven distribution without any dependencies
http://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html
Other
4 stars 10 forks source link

Get group from pillar or id command #25

Closed noelmcloughlin closed 6 years ago

noelmcloughlin commented 6 years ago

Get group from either pillar or GNU coreutils id -gn command.
Fixes failed states when users exist in LDAP and AD. Verified successfully on Ubuntu 16 with active directory users.

noelmcloughlin commented 6 years ago

The main objective is to dynamically lookup group because states fail with AD users.

{%- set group = salt['cmd.run']('id -gn', runas=user, output_loglevel='quiet',) or None %}

noelmcloughlin commented 6 years ago

Selfie-merge per community guidelines as PR is stuck a few weeks.