我有一个 Ansible 剧本,可以写入/etc/sssd/sssd.conf
这个 Jinja 模板(变量在其他地方定义):
# This line is just to check that the file is written correctly
[sssd]
domains = {{ domain }}
config_file_version = 2
services = nss, pam
[domain/{{ domain }}]
id_provider = ad
auth_provider = ad
ad_domain = {{ domain }}
ad_server = {{ ad_server }}
krb5_realm = {{ domain | upper }}
cache_credentials = true
krb5_store_password_if_offline = true
default_shell = /bin/bash
ldap_id_mapping = true
use_fully_qualified_names = false
fallback_homedir = /home/EXAMPLE/%u
access_provider = simple
simple_allow_groups = {{ simple_allow_groups }}
simple_allow_users = {{ simple_allow_users }}
ignore_group_members = true
enumerate = False
ldap_purge_cache_timeout = 0
subdomain_inherit = ignore_group_members, ldap_purge_cache_timeout
然后剧本重新启动sssd
,并执行一些realm leave
和realm join
操作。
/etc/sssd/sssd.conf
运行剧本后,服务器上的内容如下:
# This line is just to check that the file is written correctly
[sssd]
domains = example.abc
config_file_version = 2
services = nss, pam
[domain/example.abc]
default_shell = /bin/bash
krb5_store_password_if_offline = True
cache_credentials = True
krb5_realm = EXAMPLE.ABC
realmd_tags = manages-system joined-with-adcli
id_provider = ad
fallback_homedir = /home/%u@%d
ad_domain = example.abc
use_fully_qualified_names = True
ldap_id_mapping = True
access_provider = ad
什么正在改变/etc/sssd/sssd.conf
?如何改变?