The docker containers share the identity (and machine account) of the host. By default, the kerberos credential cache and keytab file are created and stored in the host computer and are not available to the docker containers.
If a kerberos application running inside the docker container needs to use the kerberos credential cache and keytab files of the host machine account, Centrify recommends the following procedure.
To configure a kerberos application in a CoreOS container to use the kerberos files of the host computer account:
- By default, the host machine account kerberos credential cache and keytab files are stored in /etc, and it is not good practice to share this directory with the containers. So, we need to use a separate directory to store and share such files.
- Set up the following in the CoreOS host computer:
- Create a directory /etc/centrify_krb5 for storing the host machine's kerberos credential cache and keytab file.
Set up the following configuration parameters in centrifydc.conf: adclient.krb5.ccache.file: /etc/centrify_krb5/krb5.ccache adclient.krb5.keytab: /etc/centrify_krb5/krb5.keytab
Note that these two parameters are effective when the host is joined to Active Directory. Please set up these two parameters before you join the CoreOS host to Active Directory.
- For the docker images:
- In the docker run command, specify -v /etc/centrify_krb5:/etc/centrify_krb5 to set up the bind mount mapping
- Point the kerberos applications/scripts to use krb5.keytab/krb5.ccache in /etc/centrify_krb5 (intead of /etc)
Please contact Centrify Technical Support if the docker applications cannot use alternate locations for the kerberos credential cache and keytab files.