When the service gets killed abruptly, the route53-sidecar doesn't get a chance to delete the A records that got added, resulting in stale records in the hosted zone.
This can also happen if the policies get removed from the service's task role, before the service is stopped. Then, when the service stops, the task no longer has permission to amend the hosted zone.
When the service gets killed abruptly, the route53-sidecar doesn't get a chance to delete the A records that got added, resulting in stale records in the hosted zone.
This can also happen if the policies get removed from the service's task role, before the service is stopped. Then, when the service stops, the task no longer has permission to amend the hosted zone.