summaryrefslogtreecommitdiffstats
path: root/install/tools
diff options
context:
space:
mode:
authorTomas Babej <tbabej@redhat.com>2013-10-09 12:23:18 +0200
committerMartin Kosek <mkosek@redhat.com>2013-10-14 11:11:17 +0200
commit4a95a50596fb86ce9de82b2c2a0517d3aa341950 (patch)
tree95f4a980cda597c10698eb8f90b53776e07de1fe /install/tools
parent285ed59889590ddd0d6ca2e2a030b28527941cbf (diff)
downloadfreeipa-4a95a50596fb86ce9de82b2c2a0517d3aa341950.tar.gz
freeipa-4a95a50596fb86ce9de82b2c2a0517d3aa341950.tar.xz
freeipa-4a95a50596fb86ce9de82b2c2a0517d3aa341950.zip
ipa-upgradeconfig: Remove backed up smb.conf
Since we are not able to properly restore the Samba server to the working state after running ipa-adtrust-install, we should not keep the smb.conf in the fstore. This patch makes sure that any backed up smb.conf is removed from the backup and that this file is not backed up anymore. Part of: https://fedorahosted.org/freeipa/ticket/3479
Diffstat (limited to 'install/tools')
-rw-r--r--install/tools/ipa-upgradeconfig14
1 files changed, 14 insertions, 0 deletions
diff --git a/install/tools/ipa-upgradeconfig b/install/tools/ipa-upgradeconfig
index 1edc4c7bf..2ee598322 100644
--- a/install/tools/ipa-upgradeconfig
+++ b/install/tools/ipa-upgradeconfig
@@ -291,6 +291,19 @@ def cleanup_kdc(fstore):
fstore.untrack_file(filename)
root_logger.debug('Uninstalling %s', filename)
+def cleanup_adtrust(fstore):
+ """
+ Clean up any old Samba backup files that were deprecated.
+ """
+
+ root_logger.info('[Checking for deprecated backups of Samba '
+ 'configuration files]')
+
+ for backed_up_file in ['/etc/samba/smb.conf']:
+ if fstore.has_file(backed_up_file):
+ fstore.untrack_file(backed_up_file)
+ root_logger.debug('Removing %s from backup', backed_up_file)
+
def setup_firefox_extension(fstore):
"""Set up the Firefox configuration extension, if it's not set up yet
@@ -1061,6 +1074,7 @@ def main():
pass
cleanup_kdc(fstore)
+ cleanup_adtrust(fstore)
setup_firefox_extension(fstore)
add_ca_dns_records()