Linux Init & Daemon Management

Systemd Service Generator & Guides

Copy-paste production systemd unit files for modern web applications, APIs, background workers, and automation timers. Run services as unprivileged users, configure automatic recovery on crash, and stream unified logs with journalctl.

Web Apps & APIsnode-app.service

How to Create a Systemd Service for Node.js (Express, NestJS, Next.js)

Production-ready systemd unit file for Node.js apps with auto-restart on crash, non-root execution, and graceful SIGINT handling.

sudo systemctl enable --now node-app
User: www-dataView Guide
Web Apps & APIspython-app.service

How to Create a Systemd Service for Python (FastAPI, Flask, Gunicorn, Uvicorn)

Robust systemd unit file for Python WSGI/ASGI apps utilizing virtualenv binaries, Uvicorn workers, and auto-restart.

sudo systemctl enable --now python-app
User: www-dataView Guide
Web Apps & APIsgo-service.service

How to Create a Systemd Service for Go (Golang) Compiled Binary

Minimal, secure systemd unit file for statically compiled Go backend binaries with sandboxing flags.

sudo systemctl enable --now go-service
User: appuserView Guide
Background Workers & Daemonsqueue-worker.service

How to Run Background Workers (Celery, BullMQ, Sidekiq) with Systemd

High-reliability systemd unit file for queue consumers and asynchronous job processors that must never stay down.

sudo systemctl enable --now queue-worker
User: workerView Guide
Timers & Automationbackup-task.service

How to Create a Systemd Timer to Replace Cron Jobs

Modern Linux cron replacement with millisecond precision, monotonic timers, and unified journalctl logging.

sudo systemctl enable --now backup-task
User: rootView Guide
Infrastructure & Tunnelsdocker-compose-app.service

How to Run Docker Compose as a Systemd Service

Manage multi-container Docker Compose stacks with systemd for automatic container booting and graceful shutdown.

sudo systemctl enable --now docker-compose-app
User: rootView Guide
Infrastructure & Tunnelsreverse-tunnel.service

How to Keep Reverse SSH Tunnel Persistent with Autossh & Systemd

Create an unkillable reverse SSH tunnel to access home servers or NAT-restricted devices from the public internet.

sudo systemctl enable --now reverse-tunnel
User: ubuntuView Guide
Web Apps & APIsspring-app.service

How to Create a Systemd Service for Java Spring Boot JAR

Enterprise systemd unit file for Java JAR executables with JVM heap tuning and non-root execution.

sudo systemctl enable --now spring-app
User: springView Guide

Essential systemctl & journalctl Commands

Core lifecycle management commands for Linux sysadmins

CommandPurposeWhen to Use
sudo systemctl daemon-reloadReload systemd unit cacheRequired immediately after creating or editing any .service file
sudo systemctl enable --now appEnable on boot AND start immediatelyInitial service launch
sudo systemctl restart appRestart active daemonAfter code updates, git pull, or npm build
sudo systemctl status appInspect state, PID, memory, and recent logsVerifying service health and diagnosing boot failures
sudo journalctl -u app -fStream real-time log outputDebugging live application errors and incoming requests

Frequently Asked Questions About Systemd Services

Frequently Asked Questions

Frequently Asked Questions

Everything you need to know regarding specifications, syntax, and security best practices.

User-created custom service files belong in `/etc/systemd/system/` (for example, `/etc/systemd/system/myapp.service`). Files in `/lib/systemd/system/` are reserved for package manager packages and should not be edited directly.