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

chore: deprecate templatebody from http check #1587

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

adityathebe
Copy link
Member

resolves: #1584

@adityathebe
Copy link
Member Author

adityathebe commented Jan 16, 2024

To avoid excessive escaping on the templates we might want to simply turn off templating on some fields. Example: we could do it via annotations

apiVersion: canaries.flanksource.com/v1
kind: Canary
metadata:
  name: http-fail
  labels:
    "Expected-Fail": "true"
  annotations:
    canary.template.disabled: 'http.body, http.url' # <-----
spec:
  interval: 30
  http:
    - endpoint: https://httpbin.demo.aws.flanksource.com/status/500
      name: http fail response code check
      responseCodes: [200]
    - endpoint: https://httpbin.demo.aws.flanksource.com/status/200
      name: http fail test expr check
      display:
        expr: string(code) + " should be 500"
      test:
        expr: code == 500

Should this be sufficient

canary.template.disabled: 'http.body, http.url'

or do we want to individually disable templating on the http check. Eg

canary.template.disabled: 'http[0].body, http[1].url'

@moshloop moshloop marked this pull request as draft March 20, 2024 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate the templateBody field in HTTP check spec
1 participant