Update yunohost_tools.py

This commit is contained in:
abeudin 2013-05-03 13:10:39 +03:00
parent fa9b528fac
commit 8a702185bf

View file

@ -92,6 +92,7 @@ def tools_maindomain(old_domain, new_domain):
'/etc/dovecot/dovecot.conf', '/etc/dovecot/dovecot.conf',
'/etc/lemonldap-ng/lemonldap-ng.ini', '/etc/lemonldap-ng/lemonldap-ng.ini',
'/etc/hosts', '/etc/hosts',
'/usr/share/yunohost/yunohost-config/others/startup',
] ]
config_dir = [] config_dir = []
@ -167,7 +168,7 @@ def tools_postinstall(domain, password):
""" """
with YunoHostLDAP(password='yunohost') as yldap: with YunoHostLDAP(password='yunohost') as yldap:
try: try:
with open('/usr/share/yunohost/yunohost-config/others/installed') as f: pass with open('/etc/yunohost/installed') as f: pass
except IOError: except IOError:
print('Installing YunoHost') print('Installing YunoHost')
else: else:
@ -182,6 +183,6 @@ def tools_postinstall(domain, password):
# Change LDAP admin password # Change LDAP admin password
tools_adminpw(old_password='yunohost', new_password=password) tools_adminpw(old_password='yunohost', new_password=password)
os.system('touch /usr/share/yunohost/yunohost-config/others/installed') os.system('touch /etc/yunohost/installed')
win_msg(_("YunoHost has been successfully configured")) win_msg(_("YunoHost has been successfully configured"))