codeql.yaml 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. name: "CodeQL"
  2. on:
  3. schedule:
  4. - cron: '33 14 * * 4'
  5. workflow_dispatch:
  6. permissions:
  7. contents: read
  8. jobs:
  9. analyze:
  10. if: github.repository == 'emqx/emqx'
  11. name: Analyze
  12. runs-on: ubuntu-22.04
  13. timeout-minutes: 360
  14. permissions:
  15. actions: read
  16. security-events: write
  17. strategy:
  18. fail-fast: false
  19. matrix:
  20. branch:
  21. - master
  22. - release-57
  23. language:
  24. - cpp
  25. - python
  26. steps:
  27. - name: Checkout repository
  28. uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
  29. with:
  30. ref: ${{ matrix.branch }}
  31. - name: Initialize CodeQL
  32. uses: github/codeql-action/init@7e187e1c529d80bac7b87a16e7a792427f65cf02 # v2.15.5
  33. with:
  34. languages: ${{ matrix.language }}
  35. - name: Build
  36. if: matrix.language == 'cpp'
  37. env:
  38. PROFILE: emqx-enterprise
  39. run: |
  40. ./scripts/buildx.sh --profile emqx-enterprise --pkgtype rel
  41. - name: Perform CodeQL Analysis
  42. uses: github/codeql-action/analyze@7e187e1c529d80bac7b87a16e7a792427f65cf02 # v2.15.5
  43. with:
  44. category: "/language:${{matrix.language}}"