/[adm]/puppet/modules/mga-common/lib/puppet/parser/functions/group_members.rb
ViewVC logotype

Contents of /puppet/modules/mga-common/lib/puppet/parser/functions/group_members.rb

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3159 - (show annotations) (download)
Thu May 23 15:06:33 2013 UTC (10 years, 11 months ago) by boklm
File size: 266 byte(s)
Move group_members function to mga-common

The group_members function currently defined in buildsystem module could
be used outside of this module, so move it to mga-common.
1 require 'etc'
2 # group_members($group)
3 # -> return a array with the login of the group members
4
5 module Puppet::Parser::Functions
6 newfunction(:group_members, :type => :rvalue) do |args|
7 group = args[0]
8 return Etc.getgrnam(group).mem
9 end
10 end

  ViewVC Help
Powered by ViewVC 1.1.30