> In some cases the infrastructure part is the least time consuming. Some platforms are straight forward enough that even manual deployment is fast. But after a hack you can’t trust anything so you need to do the slow validation that takes longer than your projected “hours”.
Your IaC is supposed to be on those offline backups too, and should be able to do everything from clean hardware.
The most time consuming part is to identify what caused the compromise. After that, you can put everything back online and then at the same time start to analyse who did it/what they did and so on. If the root cause for the breach is identified, you also know the time most likely and can trust the offline IaC backup.