mirror of
https://github.com/binwiederhier/ntfy.git
synced 2026-05-09 08:26:00 +02:00
[GH-ISSUE #419] Unable to send from curl when behind reverse proxy #323
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#323
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 @danmed on GitHub (Sep 30, 2022).
Original GitHub issue: https://github.com/binwiederhier/ntfy/issues/419
I've got everything set up and working great in docker.
If i run the below command without a reverse proxy, it all works great
curl -u user:pass -H "X-Priority: 4" -T porch.jpg -H "Filename: /root/porch.jpg" -H "Title: Someone is at the door!" -H "Actions: view, Open Camera, https://user:pass@cameraurl domain.co.uk:82/doorbellHowever if i use my reverse proxy and give it a url like ntfy.domain.co.uk (i'm using NginxProxyManager)
when running the above command, i get "301 permanently moved" error in html
My server.yml is :
@danmed commented on GitHub (Sep 30, 2022):
so it turns out this is a curl thing.. needed the below 2 switches to sort it out
-L --location-trusted
@binwiederhier commented on GitHub (Sep 30, 2022):
Sounds like your proxy isn't proxying, but rather redirecting. Look at
curl -vto see what's happening. Doesn't seem like a ntfy issue though. Feel free to close the ticket.@dioxide-jazz commented on GitHub (Jul 6, 2023):
sorry to revive a closed issue but @danmed I had this issue with nginx proxy manager and it turned out to be the fact that i had force SSL on.
since its forcing SSL its trying to redirect but cant figure it out i suppose. its almost a year later but i hope this helps you! |
@sandreas commented on GitHub (Jul 7, 2024):
For everyone running into this, here is what the sample is like:
If you are behind a proxy, this might not work. Instead you just have to fully qualify the URL including the scheme:
which made it work in my case.
Maybe this could be added to the example, if
NTFY_BEHIND_PROXY=true...?