-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Feature: Add peaNUT Widget #2450
Conversation
Ha, recognize you from the homebridge ecosystem 👍 Thanks for the PR. The only thing is, our guidelines require PRs be linked to an open request, I'd be happy to link this to #1317 but do you have any idea what the adoption of your tool is? Again, I'd be fine with it but we've had this kinda thing before and we get a lot of complaints when a widget requires a tool that most people dont have (which TBH, Im guessing is the case here, but I dont know)... |
Nice! I guess I have a reputation that precedes me. 😅 Sure. Feel free to link it to #1317. I don't have hard stats on tool adoption, but it's been steadily gaining traction. It was also featured in selfh.st which was pretty neat. I mainly created this PR for others to be able to vote on it and noticed that a generic UPS issue was already created so wasn't sure what best to do. P.S. I need to finish documentation. You responded must faster than I anticipated. 😂 |
Ok. Should be good to go. Just something for people to vote on if they want it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, we'll see what people say, this seems pretty straightforward so Im inclined to merge it unless theres something compelling there.
Tiny change, and would you mind supplying a sample of API output?
Nice proposal! Would like to see that |
Is it possible to have native support for Nut, so we don't need peaNut running? |
Co-authored-by: shamoon <[email protected]>
@shamoon Here is a sample of
|
Native support would probably be outside the scope of Homepage. There was discussion of a different approach on #1317, but either way will require intermediary code to translate NUT to a REST API. Although PeaNUT has a UI attached to it, it's the simplest way I've found so far to be able to monitor a UPS. |
What about using this module? Would it help to have native support for Nut? |
That last one is a node-client, so it could be used by a homepage widget but it would require a custom proxy, etc. which is something we generally try to avoid. The more I've looked at this, I think the simple answer is to include a note in the docs about all this. |
@Brandawg93 This works great, thanks. ![]() I fixed a missing docs link but as you can see, also added a note about all of the above. Let me know your thoughts, certainly feel free to change the wording or whatever. Otherwise Im good with this, but will await your thoughts. |
Looks good to me! That's the best part of opensource projects - users get to decide what they want to use. The other tool looks really neat too and serves a slightly different purpose than PeaNUT. NUTCase looks to be for power users looking to examine data over time. It's perfect for something like grafana. PeaNUT, on the other hand, is meant to be a path of least resistance to monitoring a UPS. Both are great for Homepage! It's up to the end user to decide what works best for them. |
I used https://github.com/dietah/nut-http instead of peaNUT. Similar default payload but with period delimiter instead of underscore in the JSON keys. Maybe add a switch for that. |
The next release of peanut will use the period in JSON instead of underscore. GraphQL isn't happy with period, so I had to change it initially. |
It has been since released, so the widget is now broken 😢 |
Whoops...I was hoping to squeeze that fix in before the release! For now you can use the template in peanut's README. |
#2526 should fix it. Just polishing it up now. |
Looks like it has been merged. P.S. I blame homepage for getting me too excited about NextJS and Tailwind. 😜 |
With Homepage v0.8.4 it's not usable in this simple form: widget: I have to use the customapi syntax, simply because a call to the api : http://host:port/api/v1/devices/[ups] is not using underscore in labels, but a period.
I'm a bit confused with the last comments here, was it or was it not part of the official merge? Changing the default back to a period? My experience tells me it's not part of 0.8.4. |
#2526 was merged but is currently only in the |
Thank you @shamoon for this clarification. By the way, nice addition to the ever growing list of widget! |
It not working on my UPS... somebody any idea, what the problem? my config:
The PeaNUT work well, also. The api/v1/devices/kstar output are:
|
@vampywiz17 It will work when homepage v0.8.5 is released. |
This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new discussion or issue for related concerns. |
Proposed change
Add support for https://github.com/Brandawg93/PeaNUT.
Type of change
Checklist: