Create trivy.yml #106
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Endor Labs Scan | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
inputs: | |
tenant_name: | |
description: "Enter your Endor Labs tenant name:" | |
required: true | |
type: string | |
jobs: | |
scan: | |
permissions: | |
security-events: write | |
contents: read | |
id-token: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v3 | |
- name: Setup Java | |
uses: actions/setup-java@v3 | |
with: | |
distribution: 'microsoft' | |
java-version: '17' | |
- name: Compile Package | |
run: mvn clean install | |
- name: Run endorctl | |
uses: endorlabs/github-action@b51bd06466b545f01a6ac788e3e1147695d3936c | |
with: | |
namespace: "${{ github.event.inputs.tenant_name }}" | |
sarif_file: findings.sarif | |
- name: Upload SARIF to github | |
uses: github/codeql-action/upload-sarif@9885f86fab4879632b7e44514f19148225dfbdcd | |
with: | |
sarif_file: findings.sarif |