todo: erect deployment deletion tomstone

This commit is contained in:
Aravinth Manivannan 2022-12-05 19:15:49 +05:30
parent f111b5c8bf
commit ee6af46ccf
Signed by: realaravinth
GPG Key ID: AD9F0F08E855ED88
1 changed files with 2 additions and 0 deletions

View File

@ -103,6 +103,8 @@ impl Ctx {
if let Ok(db_site) = self.db.get_site_from_pub_id(site_id, owner).await {
let path = get_website_path(&self.settings, &db_site.hostname);
// TODO fire delete event, but must figure out way to erect tombstone. Events link to
// sites, so deleting site record isn't possible
fs::remove_dir_all(&path).await?;
self.db
.delete_site(&db_site.owner, &db_site.hostname)