EtcUtils

Public Class Methods

getgrnam(group) click to toggle source
# File lib/openshift-origin-common/utils/etc_utils.rb, line 29
def getgrnam(group)
  return nil unless group

  Etc.getgrnam(group.to_s)
end
getpwnam(user) click to toggle source
# File lib/openshift-origin-common/utils/etc_utils.rb, line 20
def getpwnam(user)
  return nil unless user

  Etc.getpwnam(user.to_s)
end
gid(identifier) click to toggle source
# File lib/openshift-origin-common/utils/etc_utils.rb, line 47
def gid(identifier)
  if identifier.is_a?(Integer) && identifier < 4294967296
    identifier
  else
    EtcUtils.getgrnam(identifier).gid
  end
end
uid(identifier) click to toggle source
# File lib/openshift-origin-common/utils/etc_utils.rb, line 37
def uid(identifier)
  if identifier.is_a?(Integer) && identifier < 4294967296
    identifier
  else
    EtcUtils.getpwnam(identifier).uid
  end
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.