Blame SOURCES/authconfig-6.2.8-sssd-enable.patch

977b74
diff -r dfd1d988ce4b authinfo.py
977b74
--- a/authinfo.py	Tue Feb 11 11:49:42 2014 +0100
977b74
+++ b/authinfo.py	Tue Feb 11 13:01:44 2014 +0100
977b74
@@ -1218,7 +1218,7 @@
977b74
 	FileBackup("libuser.conf", SYSCONFDIR+"/libuser.conf"),
977b74
 	FileBackup("pwquality.conf", SYSCONFDIR+"/security/pwquality.conf"),
977b74
 	FileBackup("login.defs", SYSCONFDIR+"/login.defs"),
977b74
-	FileBackup("sssd.conf", SYSCONFDIR+"/sssd/sssd.conf"),
977b74
+	FileBackup("sssd.conf", PATH_SSSD_CONFIG),
977b74
 	FileBackup("shadow", SYSCONFDIR+"/shadow"),
977b74
 	FileBackup("passwd", SYSCONFDIR+"/passwd"),
977b74
 	FileBackup("gshadow", SYSCONFDIR+"/gshadow"),
977b74
@@ -4346,8 +4346,12 @@
977b74
 			"winbind", nostart)
977b74
 
977b74
 	def toggleSSSDService(self, nostart):
977b74
+		
977b74
+		explicitenable = ((self.enableSSSD and self.enableSSSDAuth) or
977b74
+			(self.enableSSSD and os.path.exists(PATH_SSSD_CONFIG)) or
977b74
+			(self.enableSSSDAuth and os.path.exists(PATH_SSSD_CONFIG)))
977b74
 		toggleSplatbindService(self.implicitSSSD or self.implicitSSSDAuth or
977b74
-			self.enableIPAv2 or self.enableSSSD or self.enableSSSDAuth,
977b74
+			self.enableIPAv2 or explicitenable,
977b74
 			PATH_SSSD,
977b74
 			"sssd", nostart or not (self.implicitSSSD or self.implicitSSSDAuth
977b74
 			or self.enableIPAv2))