-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
systemd service #113
Comments
This works great! but you should also add the working directory param or the web ui will not work properly.
|
Ah, I haven't actually used the web ui. maybe we should pool our knowledge and add it to the wiki. Would be great to add the option to start it as a service to the default packaging some how. I am not savvy when it comes to bash scripts, so I would have to look into this. |
Tried following your steps also with Rasbian, Created
However when checking the status of the service after starting it, I get
I am however able to get it working just fine via ssh by running
Any ideas? |
@ashthespy WorkingDirectory=/home/pi/spotify-connect-web/ and without -o "sysdefault:CARD=Audio" ? |
Related to #49
I've been trying to get spotifyconnectweb working seperately on a Raspberry Pi 3 headless installation and had quite a bit of problems creating a systemd service without a seperate script that cd into the directory before running spotifyconnectweb on a new line. What I've learned with help from looking at other peoples' scripts and trial and error is that unless you create a seperate script like mentioned, it seems to be very picky about accepting arguments such as --username, --password, --key etc. It just produces an error when attempting to start the service via systemctl start $servicename and doesn't start the service.
It works fine if I use the chrooted version, but not the smaller one with built-in dependencies, which is preferrable to me.
So I solved this by specifying the locations manually, which worked perfectly.
ExecStart=/pathto/spotifyconnectweb -k /pathto/spotify_appkey.key -n "Spotify Connect" -b 320 -c /pathto/credentials.json
So on my Raspbian install I have created the following service as
/etc/systemd/system/spotify-connect.service
After that I just enabled started and enabled the service
Just wanted to share this in case it helps anyone else that may be experiencing similar issues. Thank you again for your great implementation, my next issue to tackle will be starting Avahi on boot.
Would it be recommended to just add this line of code to /etc/rc.local ?
avahi-publish-service TestConnect _spotify-connect._tcp 4000 VERSION=1.0 CPath=/login/_zeroconf
Any suggestions or better implementations are welcomed!
The text was updated successfully, but these errors were encountered: