sssd_test_framework.hosts.ipa
IPA multihost host.
Classes
|
IPA host object. |
- class sssd_test_framework.hosts.ipa.IPAHost(*args, **kwargs)
Bases:
BaseDomainHost,BaseLinuxHostIPA host object.
Provides features specific to IPA server.
This class adds
config.adminpwmultihost configuration option to set password of the IPA admin user so we can obtain Kerberos TGT for the user automatically.Example multihost configuration- hostname: master.ipa.test role: ipa config: adminpw: Secret123 client: ipa_domain: ipa.test krb5_keytab: /enrollment/ipa.keytab ldap_krb5_keytab: /enrollment/ipa.keytab
Note
Full backup and restore is supported. However, the operation relies on
ipa-backupandipa-restorecommands which can take several seconds to finish.- Parameters:
auto_start – Automatically start service before taking the first backup.
auto_restore (bool, optional) – If True, the host is automatically restored to the backup state when a test is finished in
teardown(), defaults to True
- adminpw: str
Password of the admin user, defaults to
Secret123.
- adminuser: str
Administrator user, defaults to
admin.
- property features: dict[str, bool]
Features supported by the host.
- setup() None
Truncate existing IPA logs before each test to avoid need for restart.
- kinit() None
Obtain
adminuser Kerberos TGT.
- start() None
Start required services.
- Raises:
NotImplementedError – If start operation is not supported.
- stop() None
Stop required services.
- Raises:
NotImplementedError – If stop operation is not supported.
- backup() Any
Backup all IPA server data.
This is done by calling
ipa-backup --data --onlineon the server and can take several seconds to finish.- Returns:
Backup data.
- Return type:
Any
- restore(backup_data: Any | None) None
Restore all IPA server data to its original state.
This is done by calling
ipa-restore --data --onlineon the server and can take several seconds to finish.- Returns:
Backup data.
- Return type:
Any