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

Is there a way to test notifications? #90

Open
edrock200 opened this issue Jun 20, 2022 · 8 comments
Open

Is there a way to test notifications? #90

edrock200 opened this issue Jun 20, 2022 · 8 comments

Comments

@edrock200
Copy link

I have the notification webhook doing to a discord webhook, but it doesn't seem to be working. Is there. Way to test webhook notifications on demand? Thanks in advance.

@PriamX
Copy link

PriamX commented Sep 19, 2022

Same here, using a discord webhook, nothing showing up in discord. Discord is working with other webhooks. Looking for a way to troubleshoot. thanks.

@PriamX
Copy link

PriamX commented Sep 19, 2022

I've tried this three different ways with no luck. I'm deploying using docker compose, for the WEBHOOK_URL I've tried it three different ways of using quotes:

    environment:
      - "AUTOHEAL_CONTAINER_LABEL=all" # monitor all containers w/a healthcheck
      - "AUTOHEAL_INTERVAL=30"         # check every 30 seconds
      - "AUTOHEAL_START_PERIOD=180"    # wait 3 mins before first healthcheck
      - WEBHOOK_URL="https://discord.com/api/webhooks/XXXXXXXXXXX/XXXXXXXXXX"

And....

- "WEBHOOK_URL=https://discord.com/api/webhooks/XXXXXXXXXXX/XXXXXXXXXX"

Lastly (no quotes):

- WEBHOOK_URL=https://discord.com/api/webhooks/XXXXXXXXXXX/XXXXXXXXXX

@PriamX
Copy link

PriamX commented Sep 19, 2022

It doesnt work with discord as its written for slack and they are slightly different.. See the PRs for ones that do. I use the Apprise one to send to discord, email, etc.

PRs? Where can I find those? I must have missed seeing some documentation. thanks.

@PriamX
Copy link

PriamX commented Sep 19, 2022

#74 - Apprise notifications #79 - Make the webhook universal to allow it to work with discord.

You need to fork the repo, merge the PR (pull request), build the resulting docker image and push it to dockerhub or somewhere. If you arent familiar with this then you'll need to wait.

Thanks, I'm familiar, but not sure if it's worth it. For now I may just use docker logs autoheal periodically to grab any "restarting" entries and eamil or IM them to me.

Thank you for your help and the information.

@PriamX
Copy link

PriamX commented Sep 19, 2022

https://hub.docker.com/r/rxwatcher/autoheal is one with the Apprise notifications in it. You add an additional environment variable: APPRISE_URL: https://apprise.domain.com/notify/apprise?tag=my_tag

Ah, thank you, I'll give that a try.

@PriamX
Copy link

PriamX commented Sep 19, 2022

That's nice, I'll check out Apprise. I have some legacy system that could benefit with a migration to something like that. Really appreciate you pointing me that way.

@PriamX
Copy link

PriamX commented Sep 19, 2022

BTW, I don't know if it's worth mentioning, but a change on line 75 of docker-entrypoint from:

"text":"$text"

to:

"username":"autoheal","content":"$text"

Allows it to work with Discord, in a very basic way.

@stanthewizzard
Copy link

Hello
I think apprise is well configured.
Is there a way to test autoheal notification ?
Thanks

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

4 participants
@stanthewizzard @edrock200 @PriamX and others