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

[RESULT_ERRORS] parsed but empty #951

Open
SeaweedbrainCY opened this issue Dec 31, 2024 · 1 comment
Open

[RESULT_ERRORS] parsed but empty #951

SeaweedbrainCY opened this issue Dec 31, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@SeaweedbrainCY
Copy link

SeaweedbrainCY commented Dec 31, 2024

Describe the bug

First of all, thanks for this project

I am trying to configure a custom alert provider but fail to pass the result of the else check.

My custom conf is the following one :

custom:
        url:  http://*************/gatus/notify
        method : "POST"
        headers: {"X-Auth-Token": "****************"}
        body: |
          { "endpoint": "[ENDPOINT_NAME]",
            "conditions": "- [RESULT_ERRORS] -",
            "description": "[ALERT_DESCRIPTION]",
            "endpoint_url": "[ENDPOINT_URL]",
            "resolved": "[ALERT_TRIGGERED_OR_RESOLVED]"
          }
        default-alert:
          failure-threshold: 2
          success-threshold: 1
          send-on-resolved: true

What do you see?

From my webhook end, here my what I receive :

{
    "endpoint": "Calcul mental", 
    "conditions": "-  -", 
    "description": "calcul.stchepinsky.net is down", 
    "endpoint_url": "[REDACTED]",  
    "resolved": "TRIGGERED"
}

What do you expect to see?

I expect to receive the healthcheck result which works well for my endpoint as I recieve this health check on ntfy in parrallel :

🔴 [STATUS] (502) == 200
🟢 [CERTIFICATE_EXPIRATION] > 7d

List the steps that must be taken to reproduce this issue

  1. Start the application
  2. Configure a custom alert provider using the [RESULT_ERRORS] provider
  3. Configure the following endpoint :
      - name: Test
        group: "Public services"
        interval: 10s
        url: https://example.com
        conditions:
          - "[STATUS] == 200"
          - "[CERTIFICATE_EXPIRATION] > 7d"
        alerts:
          - type: custom
            description: "test is down"
          - type: ntfy
            description: "test is down"
  1. Generate an downtime or resolve it

Version

v5.15.0

Additional information

I'll try to downgrade to previous version to try if it'll resolve the issue or not. I'll post the result once down below.

@SeaweedbrainCY SeaweedbrainCY added the bug Something isn't working label Dec 31, 2024
@SeaweedbrainCY
Copy link
Author

FYI after further test I have the same issue with the following version :

  • v5.15.0
  • v5.14.0
  • v5.13.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant