There are multiple mechanism to have something start on boot-up. I don't know where the audio comes from that is specified in the .m3u
file, but certainly if it is from a network, you should make sure everything the playback needs is operational.
A simple solution might be to put the command in /etc/rc.local
as a background task.
The other thing you could look at is making an entry in /etc/init.d
. And make a link in /etc/rc2.d
(adduming 2 is the normal runlevel for a Raspberry Pi, check with runlevel
), to that file. The name should be SXY...
with XY a chosen number so that this is started (S
) after all the dependent services are up and running.
What is less likely to work is making a @reboot
entry in a crontab (assuming you have Vixie cron), not all prerequisites might be met by the time that runs.