aquasecurity / trivy-plugin-webhook

Apache License 2.0
1 stars 8 forks source link

vuls-slack template broken #17

Closed sokoow closed 1 year ago

sokoow commented 1 year ago

When I send a json output from trivy to webhook plugin, here's what I'm getting:

2023/03/24 14:54:04 route "slack-route" is associated with template "vuls-slack"
2023/03/24 14:54:04 Error while evaluating input: property title is not found

here's my postee config:

db-verify-interval: 1
  max-db-size: 1000MB

  routes:
  - name: stdout
    actions: [ stdout ]
    template: raw-json

  - name: slack-route                                 #  Route name. Must be unique
    actions: [ my-slack ]                          #  Action name (needs to be defined under "actions") which will receive the message
    template: raw-json
    plugins:
      aggregate-issues-number: null
      aggregate-issues-timeout: null
      policy-show-all: true
    output: []

  templates:
  - name: legacy-slack                    #  Legacy slack template implemented in Golang
    legacy-scan-renderer: slack
  - name: vuls-slack                  #  Out of the box template for slack
    rego-package:  postee.vuls.slack      #  Slack template REGO package (available out of the box)
  - name: raw-json                        # route message "As Is" to external webhook
    rego-package: postee.rawmessage.json

  actions:
  - name: stdout
    type: stdout
    enable: false

  - name: my-slack
    type: slack
    enable: true
    url: {{ .Values.slackHookURL }}

um, help?