Sometimes when containers are restarted automatically, is not clear why that's the case. It could be a spike in CPU usage, being out of memory or storage, etc. I have experienced situations where it's not that clear what the reason is and the crash logs (via doctl and via UI) only says that the "container was terminated", difficulting finding a solution to the issue.