Skip to content

Commit

Permalink
sssdutils: adding common mkhomedir configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
Dan Lavu committed Sep 24, 2024
1 parent 490f8b0 commit 0574303
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions sssd_test_framework/utils/sssd.py
Original file line number Diff line number Diff line change
Expand Up @@ -875,6 +875,21 @@ def autofs(self) -> None:
self.sssd.authselect.select("sssd")
self.sssd.enable_responder("autofs")

def mkhomedir(self, homedir: str = "/home") -> None:
"""
Configure SSSD with mkhomedir and oddjobd.
:param homedir: Home directory path.
:type homedir: str | None, optional
#. Select authselect sssd profile with 'with-mkhomedir'
#. Start oddjobd.service
#. Backup home directory
"""
self.sssd.authselect.select("sssd", ["with-mkhomedir"])
self.sssd.svc.start("oddjobd.service")
self.sssd.fs.backup(homedir)

def proxy(
self,
proxy: Literal["files", "ldap"] = "files",
Expand Down

0 comments on commit 0574303

Please sign in to comment.