-
Notifications
You must be signed in to change notification settings - Fork 200
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
The role installs kerberos client packages and optionally copies the configuration and credential cache from the host machine.
- Loading branch information
Showing
2 changed files
with
35 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
--- | ||
inherit_kerberos_config: '/etc/krb5.conf' | ||
inherit_kerberos_ccache: False |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
--- | ||
- name: "Install client packages on Red Hat based distributions" | ||
ansible.builtin.dnf: | ||
name: | ||
- "krb5-workstation" | ||
- "krb5-libs" | ||
state: present | ||
when: ansible_os_family == "RedHat" | ||
|
||
- name: "Install client packages on Debian based distributions" | ||
ansible.builtin.apt: | ||
name: "krb5-user" | ||
state: present | ||
when: ansible_os_family == "Debian" | ||
|
||
- name: "Copy Kerberos client configuration from Host" | ||
ansible.builtin.copy: | ||
src: "{{ inherit_kerberos_config }}" | ||
dest: /etc/krb5.conf | ||
owner: root | ||
group: root | ||
mode: '0644' | ||
when: inherit_kerberos_config | ||
|
||
- name: "Copy Kerberos credential cache from Host" | ||
ansible.builtin.copy: | ||
src: "{{ inherit_kerberos_ccache }}" | ||
dest: "{{ inherit_kerberos_ccache }}" | ||
owner: "{{ inherit_kerberos_local_user_name }}" | ||
group: "{{ inherit_kerberos_local_user_groupname | default(inherit_kerberos_local_user_name) }}" | ||
mode: '0600' | ||
when: inherit_kerberos_ccache |