diff options
-rw-r--r-- | installclass.py | 7 | ||||
-rw-r--r-- | users.py | 14 |
2 files changed, 19 insertions, 2 deletions
diff --git a/installclass.py b/installclass.py index 2c6d86e86..900d44a38 100644 --- a/installclass.py +++ b/installclass.py @@ -211,7 +211,8 @@ class BaseInstallClass: ldapBasedn = "", useKrb5 = 0, krb5Realm = "", krb5Kdc = "", krb5Admin = "", - useHesiod = 0, hesiodLhs = "", hesiodRhs = ""): + useHesiod = 0, hesiodLhs = "", hesiodRhs = "", + useSamba = 0, sambaServer= "", sambaWorkgroup = ""): id.auth.useShadow = useShadow id.auth.useMD5 = useMd5 @@ -235,6 +236,10 @@ class BaseInstallClass: id.auth.hesiodLhs = hesiodLhs id.auth.hesiodRhs = hesiodRhs + id.auth.useSamba = useSamba + id.auth.sambaServer = sambaServer + id.auth.sambaWorkgroup = sambaWorkgroup + def setNetwork(self, id, bootProto, ip, netmask, gateway, nameserver, device = None): if bootProto: @@ -131,6 +131,10 @@ class Authentication: self.hesiodLhs = "" self.hesiodRhs = "" + self.useSamba = 0 + self.sambaServer = "" + self.sambaWorkgroup = "" + def writeKS(self, f): f.write("authconfig") for arg in self.getArgList(): @@ -200,8 +204,16 @@ class Authentication: else: args.append ("--disablehesiod") - return args + if self.useSamba: + args.append ("--enablesmbauth") + args.append ("--smbservers") + args.append (self.sambaServer) + args.append ("--smbworkgroup") + args.append (self.sambaWorkgroup) + else: + args.append ("--disablesamba") + return args def write (self, instPath): args = [ "/usr/sbin/authconfig", "--kickstart", "--nostart" ] |