Skip to content
Merged
Changes from all commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ on:
its base image) and scanned. When empty (the default), image mode builds via Maven as before.
type: string
default: ''
slack_notify:
description: If true, posts an individual Slack alert on scan failure.
type: boolean
default: false
secrets:
SLACK_WEBHOOK:
required: false
Expand Down Expand Up @@ -134,7 +138,7 @@ jobs:
continue-on-error: true

- name: Notify Slack on Vulnerability Scan Failure
if: ${{ steps.vulnerability-scan.outcome == 'failure' }}
if: ${{ inputs.slack_notify && steps.vulnerability-scan.outcome == 'failure' }}
env:
SLACK_COLOR: danger
SLACK_MESSAGE: ':x: Vulnerability scan failed. Please review details: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}. Check past alerts before acting and log new actions to avoid duplicate efforts.'
Expand Down
Loading