use correct version of ktutil

parent 5ed8593b
unreleased (207x-xx-xx)
[wallet] Make wallet ketyab use the correct path for ktutil.
[duo] Change apt pin file to point to codename rather than archive
name. [adamhl]
......
......@@ -8,12 +8,19 @@ define base::wallet::keytab(
$heimdal = false
) {
include base::wallet::client
if ($::lsbdistcodename == 'wheezy') {
$ktutil_exe = '/usr/sbin/ktutil'
} else {
$ktutil_exe = '/usr/bin/ktutil'
}
$wallet_opts = "-f '$path' get keytab '$name'"
exec { "wallet $wallet_opts":
path => '/bin:/usr/bin:/usr/local/bin:/usr/kerberos/bin',
command => "${kstart_cmd} wallet ${wallet_opts}",
unless => $heimdal ? {
true => "/usr/sbin/ktutil -k '$path' list | grep -i -q '$name'",
true => "${ktutil_exe} -k '$path' list | grep -i -q '$name'",
false => "klist -k '$path' | grep -i -q '$name'",
},
require => [ Package['kstart'], Package['wallet-client'] ],
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment