Skip to content

[Notifier] Fixed authorization problems #58088

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

Closed
wants to merge 3 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Added example for token auth
  • Loading branch information
jirikmik authored Aug 26, 2024
commit db86f7f165cf31c941e4e28a208ff64bbe674995
14 changes: 11 additions & 3 deletions src/Symfony/Component/Notifier/Bridge/Ntfy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,24 @@ Provides [Ntfy](https://docs.ntfy.sh/) integration for Symfony Notifier.

DSN example
-----------

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's keep this blank line

```
NTFY_DSN=ntfy://[USER:PASSWORD]@default[:PORT]/TOPIC?[secureHttp=[on]]
NTFY_DSN=ntfy://URL[:PORT]/TOPIC?[secureHttp=[on]]
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add a whiteline after and before each code delimiter line?

or with username and password authorization:
```
NTFY_DSN=ntfy://USER:PASSWORD@URL[:PORT]/TOPIC?[secureHttp=[on]]
```
or with token authorization:
```
NTFY_DSN=ntfy://:TOKEN@URL[:PORT]/TOPIC?[secureHttp=[on]]
```
where:
- `URL` is the ntfy server which you are using
- if `default` is provided, this will default to the public ntfy server hosted on [ntfy.sh](https://ntfy.sh/).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking at README in other bridges, the example DSN uses @default directly. I think it'd be better to follow their lead as using something non-default is going to be the exception.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, I understand. But text is talking about URL which is not in example DSN. With self-hosted Ntfy is default unclear

- if value `default` is provided, this will default to the public ntfy server hosted on [ntfy.sh](https://ntfy.sh/).
- `TOPIC` is the topic on this ntfy server.
- `PORT` is an optional specific port.
- `USER`and `PASSWORD` are username and password in case of access control supported by the server
- `TOKEN` is token value provided by server for user

In case of a non-secure server, you can disable https by setting `secureHttp=off`. For example if you use a local [Ntfy Docker image](https://hub.docker.com/r/binwiederhier/ntfy) during development or testing.

Expand Down
Loading
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy