Solve the case when provisioning fails and tempalte should be deleted