Stop system from automatic sleep/ suspend?

I’ve setup an old desktop computer as a homelab server running nixOS with no DE. My config file is super simple and just sets up wireguard, docker and ssh. The only problem I have is that whenever I don’t have an open session to that machine (via ssh or on the machine itslef) it seems to go to sleep or suspend and all my services go down. Any way to solve this?

I’ve already tried powerManagement.enable = false; but it doesn’t help. Any suggestions are welcome!

If you don’t have a desktop environment, there’s nothing in stock NixOS that should put it to sleep automatically, I’m pretty sure. Might want to check your system logs to see what’s going on.