Skip to content
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

Add a poweroff button #79

Closed
meonwax opened this issue Jun 27, 2015 · 5 comments
Closed

Add a poweroff button #79

meonwax opened this issue Jun 27, 2015 · 5 comments

Comments

@meonwax
Copy link

meonwax commented Jun 27, 2015

Hi,

First of all: great project! Now a feature request by me:

It would be nice if you could implement a shutdown button to gracefully poweroff the Raspi.
Of course the system user has to be privileged but that's only a configuration issue.
Perhaps just call /sbin/poweroff or let the user configure the shutdown command himself (e.g. sudo /sbin/poweroff) with an appropriate sudoers entry.

That would enormously increase the lifetime of the filesystem.

What do you think?

@ajs124
Copy link
Contributor

ajs124 commented Jun 28, 2015

I think this sounds like feature creep. Why does a webinterface for mpd need to be able to shut down your whole device? What does any of this have to do with the "lifetime of the filesystem"?

Ympd is also not exclusive to the raspberry pi, but probably runs on everything that's POSIX compatible.

@meonwax
Copy link
Author

meonwax commented Jun 30, 2015

Every (POSIX compatible) system on which ympd is running on has to be shut down eventually. And when you run a filesystem that does not always sync will be in dirty state or at the worst will show data loss when the power is cut off abruptly.

I think a project like this could offer a solution for this with a config option. Would not be a big deal.

@szymonkaliski
Copy link

Hmm, "Every (POSIX compatible) system on which ympd is running on has to be shut down eventually" isn't this the case with all software? By this logic for example web browser should have shutdown button as well, right?

@ghost
Copy link

ghost commented Jun 30, 2015

If such a feature had indeed a place in a media server, I'd expect to see it in mpd directly, not in one of its web frontend. Why not try the request directly in mpd? If it implements a shutdown API, then it will make more sense to expose it in ympd.

@meonwax
Copy link
Author

meonwax commented Jul 9, 2015

I understand your arguments and agree with @hsoft that this may be a todo for mpd itself.
I also found a neat workaround here that i will try to implement.

Thank you for your comments. I will close this issue.

@meonwax meonwax closed this as completed Jul 9, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants