mirror of
https://github.com/binwiederhier/ntfy.git
synced 2026-05-09 08:26:00 +02:00
[GH-ISSUE #323] Web UI with Ubuntu+Firefox or MacOS+Safari - "Notifications are Disabled" "Grant Now" option has no effect #255
Labels
No labels
ai-generated
android-app
android-app
android-app
🪲 bug
build
build
dependencies
docs
enhancement
enhancement
🔥 HOT
in-progress 🏃
ios
prio:low
prio:low
pull-request
question
🔒 security
server
server
unified-push
web-app
website
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/ntfy#255
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @milksteakjellybeans on GitHub (Jun 11, 2022).
Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/323
When using the ntfy web ui on a self hosted ntfy server, I see a panel in the top left for:
When I click "GRANT NOW" action, there seems to be no effect.
This happens for both of these combinations:
Ubuntu (20.04.4 LTS) + Firefox (100.0.2)
MacOS (12.4 (21F79)) + Safari (Version 15.5 (17613.2.7.1.8))
If this isn't a supported feature on these platforms I hope it can be considered as a feature request.
Thank you
@binwiederhier commented on GitHub (Jun 12, 2022):
Hmm. Works for me: https://phil.nopaste.net/XVd5JJA4kY?a=K3aSwpEmp7
@milksteakjellybeans commented on GitHub (Jun 12, 2022):
I will gather more info and report back, thanks
@milksteakjellybeans commented on GitHub (Jun 12, 2022):
With ntfy.sh, works as expected for me in Firefox and Safari.
With my self hosted, http only server, I'm having this issue.
As far as I can tell it's the browsers not letting the prompt for notification permission through.
With Firefox, looks like it will not honor the “always ask” default setting for “send notifications” if the site is served with http, at least that's what I'm seeing for my self hosted http version.
Again, with Firefox, if I manually go to site permissions (lock icon in url bar -> connection not secure -> more information -> permissions), I can switch “Send Notifications” to allow to get notifications enabled, which now has no call to action for notifications within my self hosted site. woo hoo
With Safari, I can't find a direct way to enable the notification support "manually" outside of using Xcode to manually edit the ~/Library/Safari/UserNotificationPermissions.plist file. The site preferences menu options of safari allows editing popup and video/audio playing directly for a site, but not notifications. I don't have Xcode so I didn't try the direct edit but looking at the file in a text editor does give me confidence that a direct edit would work.
so, all in all this looks more like http+notification handling logic in the browsers.
I don't know what chrome does, but if it also doesn't work there, it might be worth considering documentation notes for self hosted or changing the call to action in the web ui when the sites running http. I know the majority of folks are w/ chrome.
Thank you for reviewing.
Safari site prefs for ref

@binwiederhier commented on GitHub (Jun 12, 2022):
Oh yeah, of course. The notifications API only works on HTTPS afaik (https://developer.mozilla.org/en-US/docs/Web/API/notification):
Probably should add a alert in the web UI. Thanks.
@binwiederhier commented on GitHub (Jun 12, 2022):
Long story short: It won't work over HTTP. Browsers are trying to push people toward HTTPS, and they do this by only allowing new features over HTTPS, even if they are completely unrelated.
@binwiederhier commented on GitHub (Jun 12, 2022):
Slight correction: It works on "localhost" (HTTP) and HTTPS-sites.
@binwiederhier commented on GitHub (Jun 12, 2022):
Added banner in
github.com/binwiederhier/ntfy@feef15c485. Thank you for reporting.@milksteakjellybeans commented on GitHub (Jun 12, 2022):
understood, ty
Firefox does seem to work with the manual settings change in place, but I'll know why if that stops working in the future