Remove some additional instances of krbV from ipa-client

Make two krbV imports conditional. These aren't used during a client
install so should cause no problems.

Also fix the client installer to use the new env option in ipautil.run.
We weren't getting the krb5 configuration set in the environment because
we were overriding the environment to set the PATH.

ticket 136
This commit is contained in:
Rob Crittenden
2010-09-10 15:57:40 -04:00
parent a091be064d
commit 67a4549519
3 changed files with 16 additions and 9 deletions

View File

@@ -20,7 +20,6 @@
import ConfigParser
from optparse import OptionParser, IndentedHelpFormatter
import krbV
import socket
import ipapython.dnsclient
import re
@@ -113,8 +112,13 @@ def __discover_config(discover_server = True):
rl = 0
try:
if not config.default_realm:
krbctx = krbV.default_context()
config.default_realm = krbctx.default_realm
try:
# only import krbV when we need it
import krbV
krbctx = krbV.default_context()
config.default_realm = krbctx.default_realm
except ImportError:
pass
if not config.default_realm:
return False