Skip to main content

rawops.dev

Skip to tool content

Systemd Service & Timer Generator

Build .service and .timer unit files for systemd interactively. Fill in the form, toggle security and limits, copy or download. 100% client-side.

[Unit]

network.target

[Service]

[Install]

multi-user.target

Generated Config

my-application.service
[Unit]
Description=My Application
After=network.target

[Service]
Type=simple
ExecStart=/usr/local/bin/myapp
Restart=on-failure
RestartSec=5

[Install]
WantedBy=multi-user.target

Quick Install

# 1. Save the file(s)

sudo cp my-application.service /etc/systemd/system/

# 2. Reload systemd

sudo systemctl daemon-reload

# 3. Enable and start

sudo systemctl enable --now my-application

# 4. Check status

sudo systemctl status my-application

Quick Recipes

Click a recipe to populate the form with a common service configuration.

Systemd Service File Guide

systemd is the default init system on most modern Linux distributions (Ubuntu, Debian, Fedora, CentOS/RHEL, Arch). Service unit files define how processes are started, stopped, and monitored. They live in /etc/systemd/system/ and use an INI-like format with three main sections. To convert between cron schedules and systemd calendar expressions, see the Cron ↔ Systemd Timer Converter.

Unit File Structure

[Unit]
Description=My Application
After=network.target

[Service]
Type=simple
ExecStart=/usr/local/bin/myapp
Restart=on-failure

[Install]
WantedBy=multi-user.target

Service Types Explained

TypeWhen to useExample
simpleDefault. Process stays in foreground.Node.js, Go, Python
execLike simple, but “started” only after exec() succeedsGunicorn, Java
forkingProcess forks to background. Needs PIDFile.Apache, traditional daemons
oneshotRuns once and exits. Good for scripts.Migrations, cleanup scripts
notifyProcess sends sd_notify() when readyNginx, Caddy, PostgreSQL
idleWaits for all other jobs to finishLow-priority tasks

Common Commands

CommandDescription
systemctl start myappStart the service
systemctl stop myappStop the service
systemctl restart myappRestart the service
systemctl enable myappStart on boot
systemctl status myappCheck status and recent logs
journalctl -u myapp -fFollow live logs
systemctl daemon-reloadReload after editing unit files

Security Hardening

  • NoNewPrivileges — prevents privilege escalation via setuid/setgid binaries
  • ProtectSystem — makes /usr, /boot, /efi read-only (full adds /etc, strict makes everything read-only)
  • ProtectHome — makes /home, /root, /run/user inaccessible
  • PrivateTmp — gives the service its own /tmp namespace
  • PrivateDevices — restricts access to physical devices
  • ReadWritePaths — whitelist writable directories when using ProtectSystem=strict

Privacy First

All configuration is generated entirely in your browser using JavaScript. Your service paths, usernames, environment variables, and infrastructure details are never sent to any server.

Related Tools & Resources