Skip to content

Merge pull request #301 from govuk-one-login/dependabot/npm_and_yarn/… #1124

Merge pull request #301 from govuk-one-login/dependabot/npm_and_yarn/…

Merge pull request #301 from govuk-one-login/dependabot/npm_and_yarn/… #1124

Workflow file for this run

name: Scan repository
on:
pull_request:
push:
branches: [main]
schedule:
# Every Monday at 9am
- cron: "0 9 * * 1"
concurrency:
group: scan-repo-${{ github.head_ref || github.ref_name }}
cancel-in-progress: true
permissions: {}
jobs:
coverage:
name: Collect coverage
if: ${{ github.event_name != 'pull_request' }}
uses: ./.github/workflows/run-unit-tests.yml
with:
coverage-report: true
sonarcloud:
name: SonarCloud
needs: coverage
runs-on: ubuntu-latest
if: ${{ success() || needs.coverage.result == 'skipped' }}
steps:
- name: Run SonarCloud scan
uses: govuk-one-login/github-actions/code-quality/sonarcloud@e6b6ed890b35904e1be79f7f35ffec983fa4d9db
with:
sonar-token: ${{ secrets.SONAR_TOKEN }}
github-token: ${{ secrets.GITHUB_TOKEN }}
coverage-artifact: ${{ needs.coverage.outputs.coverage-artifact || 'coverage' }}
codeql:
name: CodeQL
runs-on: ubuntu-latest
permissions:
security-events: write
steps:
- name: Run CodeQL scan
uses: govuk-one-login/github-actions/code-quality/codeql@e6b6ed890b35904e1be79f7f35ffec983fa4d9db
with:
languages: javascript-typescript