mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Remove a bunch of unused imports, general cleanup
This commit is contained in:
committed by
Jason Gerard DeRose
parent
192cccea97
commit
725656119c
@@ -22,17 +22,14 @@ Joining an IPA domain
|
||||
"""
|
||||
|
||||
from ipalib import api, util
|
||||
from ipalib import Command, Str, Int
|
||||
from ipalib import Command, Str
|
||||
from ipalib import errors
|
||||
import krbV
|
||||
import os, subprocess
|
||||
from ipapython import ipautil
|
||||
import tempfile
|
||||
import sha
|
||||
import stat
|
||||
import shutil
|
||||
|
||||
def get_realm():
|
||||
"""
|
||||
Returns the default kerberos realm configured for this server.
|
||||
"""
|
||||
krbctx = krbV.default_context()
|
||||
|
||||
return unicode(krbctx.default_realm)
|
||||
@@ -49,8 +46,6 @@ def validate_host(ugettext, cn):
|
||||
class join(Command):
|
||||
"""Join an IPA domain"""
|
||||
|
||||
requires_root = True
|
||||
|
||||
takes_args = (
|
||||
Str('cn',
|
||||
validate_host,
|
||||
@@ -113,8 +108,4 @@ class join(Command):
|
||||
|
||||
return (dn, attrs_list)
|
||||
|
||||
def output_for_cli(self, textui, result, args, **options):
|
||||
textui.print_plain("Welcome to the %s realm" % options['realm'])
|
||||
textui.print_plain("Your keytab is in %s" % result.get('keytab'))
|
||||
|
||||
api.register(join)
|
||||
|
||||
Reference in New Issue
Block a user