summaryrefslogtreecommitdiffstats
path: root/ipaserver/install/odsexporterinstance.py
diff options
context:
space:
mode:
authorTimo Aaltonen <tjaalton@debian.org>2016-03-18 12:22:33 +0200
committerMartin Basti <mbasti@redhat.com>2016-03-23 13:32:55 +0100
commit2a2d63669d740396eabc6f46906b8625f001ad3c (patch)
tree08688e009a46057e86f6198d42ced3289d00a23c /ipaserver/install/odsexporterinstance.py
parentd58cd04e8a618b0bf33d36099f782149c93dbd33 (diff)
downloadfreeipa-2a2d63669d740396eabc6f46906b8625f001ad3c.tar.gz
freeipa-2a2d63669d740396eabc6f46906b8625f001ad3c.tar.xz
freeipa-2a2d63669d740396eabc6f46906b8625f001ad3c.zip
ipaplatform: Move remaining user/group constants to ipaplatform.constants.
Use ipaplatform.constants in every corner instead of importing other bits or calling some platform specific things, and remove most of the remaining hardcoded uid's. https://fedorahosted.org/freeipa/ticket/5343 Reviewed-By: David Kupka <dkupka@redhat.com>
Diffstat (limited to 'ipaserver/install/odsexporterinstance.py')
-rw-r--r--ipaserver/install/odsexporterinstance.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/ipaserver/install/odsexporterinstance.py b/ipaserver/install/odsexporterinstance.py
index e761ebcde..e9f7bf853 100644
--- a/ipaserver/install/odsexporterinstance.py
+++ b/ipaserver/install/odsexporterinstance.py
@@ -13,6 +13,7 @@ from ipaserver.install import installutils
from ipapython.ipa_log_manager import root_logger
from ipapython.dn import DN
from ipapython import sysrestore, ipautil, ipaldap
+from ipaplatform.constants import constants
from ipaplatform.paths import paths
from ipaplatform import services
from ipalib import errors, api
@@ -68,12 +69,12 @@ class ODSExporterInstance(service.Service):
ods_enforcerd = services.knownservices.ods_enforcerd
try:
- self.ods_uid = pwd.getpwnam(ods_enforcerd.get_user_name()).pw_uid
+ self.ods_uid = pwd.getpwnam(constants.ODS_USER).pw_uid
except KeyError:
raise RuntimeError("OpenDNSSEC UID not found")
try:
- self.ods_gid = grp.getgrnam(ods_enforcerd.get_group_name()).gr_gid
+ self.ods_gid = grp.getgrnam(constants.ODS_GROUP).gr_gid
except KeyError:
raise RuntimeError("OpenDNSSEC GID not found")