minor build updates #2130
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: Semgrep | |
permissions: read-all | |
on: | |
pull_request: {} | |
push: | |
branches: [master, v2.dev, v3.dev] | |
jobs: | |
semgrep: | |
name: Scan | |
runs-on: ubuntu-latest | |
permissions: | |
actions: read | |
contents: read | |
security-events: write | |
container: | |
image: returntocorp/semgrep | |
steps: | |
- name: Harden Runner | |
uses: step-security/harden-runner@8ca2b8b2ece13480cda6dacd3511b49857a23c09 # v2.5.1 | |
with: | |
disable-sudo: true | |
egress-policy: audit | |
- uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac # v4.0.0 | |
- run: semgrep scan --sarif --output=semgrep.sarif | |
env: | |
SEMGREP_RULES: >- | |
p/java | |
p/github-actions | |
p/semgrep-rule-lints | |
p/semgrep-misconfigurations | |
- name: Check file existence | |
id: check_files | |
uses: andstor/file-existence-action@20b4d2e596410855db8f9ca21e96fbe18e12930b # v2.0.0 | |
with: | |
files: semgrep.sarif | |
- name: Upload SARIF file for GitHub Advanced Security Dashboard | |
uses: github/codeql-action/upload-sarif@cdcdbb579706841c47f7063dda365e292e5cad7a # v2.13.4 | |
if: steps.check_files.outputs.files_exists == 'true' | |
with: | |
sarif_file: semgrep.sarif |