summaryrefslogtreecommitdiffstats
path: root/ipalib
diff options
context:
space:
mode:
authorEndi Sukma Dewata <edewata@redhat.com>2011-12-20 19:45:57 -0600
committerSimo Sorce <ssorce@redhat.com>2012-01-11 12:04:22 -0500
commit18fa8baded287fd7c811eb3e60e065e2d2d5f776 (patch)
tree18e956f14416a001184ce9a473b558c7e3d3bae8 /ipalib
parent64147cd61e303fe93a809faac9d7f4291ab47f90 (diff)
downloadfreeipa.git-18fa8baded287fd7c811eb3e60e065e2d2d5f776.tar.gz
freeipa.git-18fa8baded287fd7c811eb3e60e065e2d2d5f776.tar.xz
freeipa.git-18fa8baded287fd7c811eb3e60e065e2d2d5f776.zip
Reload UI on server upgrade.
The JSON server has been modified to return the version number in all responses. The UI has been modified to keep the version obtained during env operation and check the version returned in subsequent operations. If the version changes the UI will reload itself. Ticket #946
Diffstat (limited to 'ipalib')
-rw-r--r--ipalib/constants.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/ipalib/constants.py b/ipalib/constants.py
index 96cf3ba6..d984bbc2 100644
--- a/ipalib/constants.py
+++ b/ipalib/constants.py
@@ -22,6 +22,7 @@
All constants centralised in one file.
"""
import socket
+from ipapython.version import VERSION
try:
FQDN = socket.getfqdn()
except:
@@ -63,6 +64,8 @@ CONFIG_SECTION = 'global'
# This is a tuple instead of a dict so that it is immutable.
# To create a dict with this config, just "d = dict(DEFAULT_CONFIG)".
DEFAULT_CONFIG = (
+ ('version', VERSION),
+
# Domain, realm, basedn:
('domain', 'example.com'),
('realm', 'EXAMPLE.COM'),