Remove certs at domain deletion

This commit is contained in:
Kload 2013-06-08 17:52:39 +00:00
parent 92d3c58ea9
commit c253800081

View file

@ -182,6 +182,7 @@ def domain_remove(domains):
for domain in domains: for domain in domains:
if yldap.remove('virtualdomain=' + domain + ',ou=domains'): if yldap.remove('virtualdomain=' + domain + ',ou=domains'):
try: try:
shutil.rmtree('/etc/yunohost/certs/'+ domain)
os.remove('/var/lib/bind/'+ domain +'.zone') os.remove('/var/lib/bind/'+ domain +'.zone')
except: except:
pass pass