module documentation

Script to ensure permissions on files/dirs are accurate.

Function EnsureQueueDir Sets the correct permissions on all job files in the queue.
Function GetPaths Returns a tuple of path objects to process.
Function Main Main routine.
Function ParseOptions Parses the options passed to the program.
Function ProcessPath Processes a path component.
Function RecursiveEnsure Ensures permissions recursively down a directory.
Constant ALL_TYPES Undocumented
Constant DIR Undocumented
Constant FILE Undocumented
Constant QUEUE_DIR Undocumented
def EnsureQueueDir(path, mode, uid, gid):

Sets the correct permissions on all job files in the queue.

Parameters
pathDirectory path
modeWanted file mode
uidWanted user ID
gidWanted group ID
def GetPaths():

Returns a tuple of path objects to process.

def Main():

Main routine.

def ParseOptions():

Parses the options passed to the program.

Returns
Options and arguments
def ProcessPath(path):

Processes a path component.

Parameters
pathA tuple of the path component to process
def RecursiveEnsure(path, uid, gid, dir_perm, file_perm):

Ensures permissions recursively down a directory.

This functions walks the path and sets permissions accordingly.

Parameters
pathThe absolute path to walk
uidThe uid used as owner
gidThe gid used as group
dir_permThe permission bits set for directories
file_permThe permission bits set for files
ALL_TYPES =

Undocumented

Value
compat.UniqueFrozenset([DIR, FILE, QUEUE_DIR])
DIR =

Undocumented

FILE =

Undocumented

QUEUE_DIR =

Undocumented