codeql.yml 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. # For most projects, this workflow file will not need changing; you simply need
  2. # to commit it to your repository.
  3. #
  4. # You may wish to alter this file to override the set of languages analyzed,
  5. # or to provide custom queries or build logic.
  6. #
  7. # ******** NOTE ********
  8. # We have attempted to detect the languages in your repository. Please check
  9. # the `language` matrix defined below to confirm you have the correct set of
  10. # supported CodeQL languages.
  11. #
  12. name: "CodeQL"
  13. on:
  14. push:
  15. branches: [ "main" ]
  16. pull_request:
  17. # The branches below must be a subset of the branches above
  18. branches: [ "main" ]
  19. schedule:
  20. - cron: '17 2 * * 2'
  21. jobs:
  22. analyze:
  23. name: Analyze
  24. runs-on: ubuntu-latest
  25. permissions:
  26. actions: read
  27. contents: read
  28. security-events: write
  29. strategy:
  30. fail-fast: false
  31. matrix:
  32. language: [ 'python' ]
  33. steps:
  34. - name: Checkout repository
  35. uses: actions/checkout@v3
  36. - name: Setup Python 3.11
  37. uses: actions/setup-python@v4
  38. with:
  39. python-version: 3.11
  40. architecture: x64
  41. # Initializes the CodeQL tools for scanning.
  42. - name: Initialize CodeQL
  43. uses: github/codeql-action/init@v2
  44. with:
  45. languages: ${{ matrix.language }}
  46. # Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
  47. # If this step fails, then you should remove it and run the build manually (see below)
  48. - name: Autobuild
  49. uses: github/codeql-action/autobuild@v2
  50. - name: Perform CodeQL Analysis
  51. uses: github/codeql-action/analyze@v2
  52. with:
  53. category: "/language:${{matrix.language}}"
  54. - name: Security vulnerabilities scan
  55. uses: aufdenpunkt/python-safety-check@master