[Unit] Description=DECNET Swarm Controller (master) Documentation=https://github.com/4nt11/DECNET/wiki/SWARM-Mode After=network-online.target decnet-api.service Wants=network-online.target [Service] Type=simple User=decnet Group=decnet WorkingDirectory=/opt/decnet EnvironmentFile=-/opt/decnet/.env.local # Default bind is loopback — the controller is a master-local orchestrator # reached by the CLI and the web dashboard, not by workers. ExecStart=/opt/decnet/venv/bin/decnet swarmctl --host 127.0.0.1 --port 8770 # No special capabilities — the controller issues mTLS certs and talks to # workers over TCP on unprivileged ports. CapabilityBoundingSet= AmbientCapabilities= # Security Hardening NoNewPrivileges=yes ProtectSystem=full ProtectHome=read-only PrivateTmp=yes ProtectKernelTunables=yes ProtectKernelModules=yes ProtectControlGroups=yes RestrictSUIDSGID=yes LockPersonality=yes # Reads/writes the CA bundle and the master DB. ReadWritePaths=/opt/decnet /var/log/decnet ReadOnlyPaths=/etc/decnet Restart=on-failure RestartSec=5 [Install] WantedBy=multi-user.target