From eeff0efa5ebdce4b9bc5e3bbfd7c01609934785a Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Tue, 28 Jun 2022 07:57:32 -0700 Subject: [PATCH 1/5] Create codeql-analysis.yml --- .github/workflows/codeql-analysis.yml | 72 +++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 .github/workflows/codeql-analysis.yml diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml new file mode 100644 index 000000000..b37e23261 --- /dev/null +++ b/.github/workflows/codeql-analysis.yml @@ -0,0 +1,72 @@ +# For most projects, this workflow file will not need changing; you simply need +# to commit it to your repository. +# +# You may wish to alter this file to override the set of languages analyzed, +# or to provide custom queries or build logic. +# +# ******** NOTE ******** +# We have attempted to detect the languages in your repository. Please check +# the `language` matrix defined below to confirm you have the correct set of +# supported CodeQL languages. +# +name: "CodeQL" + +on: + push: + branches: [ "main", v1.99 ] + pull_request: + # The branches below must be a subset of the branches above + branches: [ "main" ] + schedule: + - cron: '41 16 * * 0' + +jobs: + analyze: + name: Analyze + runs-on: ubuntu-latest + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + matrix: + language: [ 'javascript', 'ruby' ] + # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] + # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v2 + with: + languages: ${{ matrix.language }} + # If you wish to specify custom queries, you can do so here or in a config file. + # By default, queries listed here will override any specified in a config file. + # Prefix the list here with "+" to use these queries and those in the config file. + + # Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs + # queries: security-extended,security-and-quality + + + # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). + # If this step fails, then you should remove it and run the build manually (see below) + - name: Autobuild + uses: github/codeql-action/autobuild@v2 + + # ℹī¸ Command-line programs to run using the OS shell. + # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun + + # If the Autobuild fails above, remove it and uncomment the following three lines. + # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance. + + # - run: | + # echo "Run, Build Application using script" + # ./location_of_script_within_repo/buildscript.sh + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v2 From ac036df29cd28e6ba079dc7feaaf1e0ffe02208d Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Tue, 28 Jun 2022 08:06:28 -0700 Subject: [PATCH 2/5] Update codeql-analysis.yml --- .github/workflows/codeql-analysis.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index b37e23261..a7cc1f3b0 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -45,6 +45,8 @@ jobs: uses: github/codeql-action/init@v2 with: languages: ${{ matrix.language }} + paths-ignore: + - app/assets/good_job/vendor # If you wish to specify custom queries, you can do so here or in a config file. # By default, queries listed here will override any specified in a config file. # Prefix the list here with "+" to use these queries and those in the config file. From 3429d18ea66d35d4266091503ae6810d2f4a772e Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Tue, 28 Jun 2022 08:09:35 -0700 Subject: [PATCH 3/5] Create codeql-config.yml --- .github/codeql/.github/codeql/codeql-config.yml | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .github/codeql/.github/codeql/codeql-config.yml diff --git a/.github/codeql/.github/codeql/codeql-config.yml b/.github/codeql/.github/codeql/codeql-config.yml new file mode 100644 index 000000000..49241962d --- /dev/null +++ b/.github/codeql/.github/codeql/codeql-config.yml @@ -0,0 +1,3 @@ +name: "GoodJob CodeQL config" +paths-ignore: + - app/assets/good_job/vendor From 1ccb9ff880b83a93f53ca95da14525621c4e427d Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Tue, 28 Jun 2022 08:10:12 -0700 Subject: [PATCH 4/5] Update codeql-analysis.yml --- .github/workflows/codeql-analysis.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index a7cc1f3b0..31fab852d 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -45,8 +45,7 @@ jobs: uses: github/codeql-action/init@v2 with: languages: ${{ matrix.language }} - paths-ignore: - - app/assets/good_job/vendor + config-file: ./.github/codeql/codeql-config.yml # If you wish to specify custom queries, you can do so here or in a config file. # By default, queries listed here will override any specified in a config file. # Prefix the list here with "+" to use these queries and those in the config file. From b86000930f1ddb6d34cb3ad4c65214dea00e6a30 Mon Sep 17 00:00:00 2001 From: "Ben Sheldon [he/him]" Date: Tue, 28 Jun 2022 08:12:38 -0700 Subject: [PATCH 5/5] Move codeql-config.yml --- .github/codeql/{.github/codeql => }/codeql-config.yml | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/codeql/{.github/codeql => }/codeql-config.yml (100%) diff --git a/.github/codeql/.github/codeql/codeql-config.yml b/.github/codeql/codeql-config.yml similarity index 100% rename from .github/codeql/.github/codeql/codeql-config.yml rename to .github/codeql/codeql-config.yml