mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-19 02:37:24 +08:00
fix(region): dns zone cache purge
This commit is contained in:
@@ -2139,6 +2139,16 @@ func (self *SCloudaccount) RealDelete(ctx context.Context, userCred mcclient.Tok
|
||||
return errors.Wrapf(err, "project %s Delete", projects[i].Id)
|
||||
}
|
||||
}
|
||||
caches, err := self.GetDnsZoneCaches()
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "GetDnsZoneCaches")
|
||||
}
|
||||
for i := range caches {
|
||||
err = caches[i].RealDelete(ctx, userCred)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "dns zone cache %s delete", caches[i].Id)
|
||||
}
|
||||
}
|
||||
return self.SEnabledStatusInfrasResourceBase.Delete(ctx, userCred)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user