summaryrefslogtreecommitdiffstats
path: root/ipa-client
diff options
context:
space:
mode:
authorMartin Kosek <mkosek@redhat.com>2011-03-24 11:01:40 +0100
committerMartin Kosek <mkosek@redhat.com>2011-04-29 09:23:59 +0200
commitd76b9aef39fa0965a0e741d16dcbf9c3279d1af5 (patch)
treeb2c4e74f214fa53e3d24fad4ae0b55c5c636fe91 /ipa-client
parent1dd7364b7b0e26c09884b045afbc9736b9340ee5 (diff)
downloadfreeipa-d76b9aef39fa0965a0e741d16dcbf9c3279d1af5.tar.gz
freeipa-d76b9aef39fa0965a0e741d16dcbf9c3279d1af5.tar.xz
freeipa-d76b9aef39fa0965a0e741d16dcbf9c3279d1af5.zip
Prevent uninstalling client on the IPA server
This patch prevents uninstalling IPA client when it is configured as a part of IPA server. ipa-server-installation script is advised for this situation. https://fedorahosted.org/freeipa/ticket/1049
Diffstat (limited to 'ipa-client')
-rwxr-xr-xipa-client/ipa-install/ipa-client-install6
1 files changed, 6 insertions, 0 deletions
diff --git a/ipa-client/ipa-install/ipa-client-install b/ipa-client/ipa-install/ipa-client-install
index c409fe706..587169ada 100755
--- a/ipa-client/ipa-install/ipa-client-install
+++ b/ipa-client/ipa-install/ipa-client-install
@@ -189,6 +189,12 @@ def uninstall(options, env):
print "IPA client is not configured on this system."
return 2
+ server_fstore = sysrestore.FileStore('/var/lib/ipa/sysrestore')
+ if server_fstore.has_files():
+ print "IPA client is configured as a part of IPA server on this system."
+ print "Please refer to ipa-server-install for uninstallation."
+ return 2
+
sssdconfig = SSSDConfig.SSSDConfig()
sssdconfig.import_config()
domains = sssdconfig.list_active_domains()