Re: [Freeipa-devel] [PATCH 0342] Use domain level constants in topology plugin

2015-11-10 Thread Martin Basti



On 10.11.2015 12:59, David Kupka wrote:

On 03/11/15 10:45, Martin Basti wrote:

Patch attached.



Works for me, ACK.


Pushed to master: c339abbad1e82a264afc5cf9efa3aff80814aeaf

--
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code


Re: [Freeipa-devel] [PATCH 0342] Use domain level constants in topology plugin

2015-11-10 Thread David Kupka

On 03/11/15 10:45, Martin Basti wrote:

Patch attached.



Works for me, ACK.

--
David Kupka

--
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code


[Freeipa-devel] [PATCH 0342] Use domain level constants in topology plugin

2015-11-03 Thread Martin Basti

Patch attached.
From 16aa96f0446a7b351763fc8061497d82fdeedbdf Mon Sep 17 00:00:00 2001
From: Martin Basti 
Date: Tue, 3 Nov 2015 10:37:15 +0100
Subject: [PATCH] Use domain level constants in topology plugin

---
 ipalib/plugins/topology.py | 7 +++
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/ipalib/plugins/topology.py b/ipalib/plugins/topology.py
index 2b82215e273d959fdb207801ed146b843460bae5..2c43758c3136a546a50472cf97d79129d1d6c738 100644
--- a/ipalib/plugins/topology.py
+++ b/ipalib/plugins/topology.py
@@ -12,6 +12,7 @@ from ipalib.plugins.baseldap import (
 LDAPRetrieve)
 from ipalib import _, ngettext
 from ipalib import output
+from ipalib.constants import DOMAIN_LEVEL_1
 from ipalib.util import create_topology_graph, get_topology_connection_errors
 from ipapython.dn import DN
 
@@ -28,15 +29,13 @@ Requires minimum domain level 1.
 
 register = Registry()
 
-MINIMUM_DOMAIN_LEVEL = 1
-
 
 def validate_domain_level(api):
 current = int(api.Command.domainlevel_get()['result'])
-if current < MINIMUM_DOMAIN_LEVEL:
+if current < DOMAIN_LEVEL_1:
 raise errors.InvalidDomainLevelError(
 reason=_('Topology management requires minimum domain level {0} '
-   .format(MINIMUM_DOMAIN_LEVEL))
+   .format(DOMAIN_LEVEL_1))
 )
 
 
-- 
2.4.3

-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code