rtail
rtail copied to clipboard
Not receiving logs from systemd service
echo on the terminal works, but a node.js systemd service doesn't :(
@thelinuxlich did you figure what's wrong?
I've did a hack, created a rtail service which people can use for now:
[Unit]
Description=rtail
After=service_you_want_to_log.service
[Service]
WorkingDirectory=/home/your_user
ExecStart=/usr/bin/bash -c '/usr/bin/sudo journalctl -u service_you_want_to_log -f | rtail --host rtail_host'
Restart=always
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=rtail
User=your_user
Group=your_user
[Install]
WantedBy=multi-user.target
Oh cool, but I still want to know if the issue was your particular use case or systemd or in rtail, if it's the second I want to fix it.
I don't have enough knowledge to say it's all systemd fault
what happens if you do > file.log ? what is the exact command you are trying to launch ?
tailing the stdout or redirecting inside the service doesn't work :(