I'm trying to get a nodejs server to run on startup, so I created the following systemd unit file:
Description=TI SensorTag Communicator
If there is no mention of the service at all in the output of
journalctl that could indicate that the service was not enabled to start at boot.
Make you run
systemctl enable my-unit-name before your next boot test.
Also, since you depend on MySQL being up and running, you should declare that with something like:
After=mysql.service. The exact service name may depend on your Linux distribution, which you didn't state.
User=root adds nothing, as system units would be run by root by default anyway.
When you said "it fails", you didn't specify whether it was failing at boot time, or with a test run by
systemctl start my-unit-name.
After attempting to start a service, there should be logging if you run
journalctl -u my-unit.name.service.
You might also consider adding
StandardOutput=journal to your unit file to make sure you capture output from the service you are running as well.