There are different init system and tools to run an application as a daemon without having to increase your application's complexity. Currently a lot of distributions ship systemd by default as it provides features like automated health check and restart and security sandboxing.
I wrote a little tool [1] that generates a template for Nim projects and ships an example .service file. [1] [https://github.com/FedericoCeratto/nim_project_maker](https://github.com/FedericoCeratto/nim_project_maker)