Sha256: c9dcc312e62ec08842211005e1dc09b1be59443764d919224e8b53f50ab0755f
Contents?: true
Size: 389 Bytes
Versions: 26
Compression:
Stored size: 389 Bytes
Contents
def user_is_in_role?(username) return false if !@node[:role] Chef::Log.info role[:groups].inspect role[:groups].include? get_user(username)[:group] end def role @node[:roles][@node[:role]] end # method name 'user' conflicts with chef, so we use 'get_user' def get_user(username) Chef::Log.info username user = @node[:users][username] Chef::Log.info user.inspect user end
Version data entries
26 entries across 26 versions & 1 rubygems