I have a simple node.js script that accepts console commands using readline. I've set it up to run as a systemd service (on Debian 9):
[Unit] Description=Web Game Server [Service] ExecStart=/usr/bin/node /var/www/index.js Restart=always Environment=NODE_ENV=production [Install] WantedBy=multi-user.target
When running directly from the console with
node index.js I'm able to send commands to it through the console. Is there any way to do this while it's running as a service?