From 995e24cf7115612c96c84d3778991ee4195dad33 Mon Sep 17 00:00:00 2001 From: Deep Vijay Poharkar Date: Tue, 6 May 2025 16:07:36 +0530 Subject: [PATCH 1/3] added sonarqube analysis --- .github/workflows/Algolia-crawler-stage.yml | 12 ++++++++++++ .github/workflows/pr.yml | 12 ++++++++++++ .github/workflows/typesense-crawler-stage.yml | 12 ++++++++++++ sonar-project.properties | 1 + 4 files changed, 37 insertions(+) create mode 100644 sonar-project.properties diff --git a/.github/workflows/Algolia-crawler-stage.yml b/.github/workflows/Algolia-crawler-stage.yml index 5cc0de820..db3b75da5 100644 --- a/.github/workflows/Algolia-crawler-stage.yml +++ b/.github/workflows/Algolia-crawler-stage.yml @@ -13,9 +13,21 @@ on: # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: # This workflow contains a single job called "build" + sonarqube-analysis: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v2 + + - name: SonarQube Analysis + uses: SonarSource/sonarqube-scan-action@master + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build: # The type of runner that the job will run on runs-on: ubuntu-latest + needs: sonarqube-analysis environment: stage # Steps represent a sequence of tasks that will be executed as part of the job steps: diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 3506b2e5e..112591092 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -8,8 +8,20 @@ on: merge_group: jobs: + sonarqube-analysis: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v4 + + - name: SonarQube Analysis + uses: SonarSource/sonarqube-scan-action@master + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build-and-deploy: runs-on: ubuntu-20.04 + needs: sonarqube-analysis env: CI: true NODE_ENV: stage diff --git a/.github/workflows/typesense-crawler-stage.yml b/.github/workflows/typesense-crawler-stage.yml index 97a86bc01..cf692bf20 100644 --- a/.github/workflows/typesense-crawler-stage.yml +++ b/.github/workflows/typesense-crawler-stage.yml @@ -7,9 +7,21 @@ on: - stage jobs: + sonarqube-analysis: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v2 + + - name: SonarQube Analysis + uses: SonarSource/sonarqube-scan-action@master + env: + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} + SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build: # The type of runner that the job will run on runs-on: ubuntu-latest + needs: sonarqube-analysis # environment: stage steps: - name: Checkout Repository diff --git a/sonar-project.properties b/sonar-project.properties new file mode 100644 index 000000000..0c7c0800f --- /dev/null +++ b/sonar-project.properties @@ -0,0 +1 @@ +sonar.projectKey=LambdaTest_documentation_AZalKzdg-ZKsnB8M0r3H \ No newline at end of file From 4c0b9d83f30198841e00976a603f19e92b67422f Mon Sep 17 00:00:00 2001 From: Deep Vijay Poharkar Date: Tue, 6 May 2025 18:18:26 +0530 Subject: [PATCH 2/3] removed build constraint --- .github/workflows/Algolia-crawler-stage.yml | 1 - .github/workflows/pr.yml | 1 - .github/workflows/typesense-crawler-stage.yml | 1 - 3 files changed, 3 deletions(-) diff --git a/.github/workflows/Algolia-crawler-stage.yml b/.github/workflows/Algolia-crawler-stage.yml index db3b75da5..3e7276a79 100644 --- a/.github/workflows/Algolia-crawler-stage.yml +++ b/.github/workflows/Algolia-crawler-stage.yml @@ -27,7 +27,6 @@ jobs: build: # The type of runner that the job will run on runs-on: ubuntu-latest - needs: sonarqube-analysis environment: stage # Steps represent a sequence of tasks that will be executed as part of the job steps: diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 112591092..63133b7ad 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -21,7 +21,6 @@ jobs: SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build-and-deploy: runs-on: ubuntu-20.04 - needs: sonarqube-analysis env: CI: true NODE_ENV: stage diff --git a/.github/workflows/typesense-crawler-stage.yml b/.github/workflows/typesense-crawler-stage.yml index cf692bf20..3917b296b 100644 --- a/.github/workflows/typesense-crawler-stage.yml +++ b/.github/workflows/typesense-crawler-stage.yml @@ -21,7 +21,6 @@ jobs: build: # The type of runner that the job will run on runs-on: ubuntu-latest - needs: sonarqube-analysis # environment: stage steps: - name: Checkout Repository From 1b286233aed36b913923f2daed318cd4cbbf0a34 Mon Sep 17 00:00:00 2001 From: Deep Vijay Poharkar Date: Wed, 7 May 2025 16:19:46 +0530 Subject: [PATCH 3/3] removed from typesense and algolia --- .github/workflows/Algolia-crawler-stage.yml | 11 ----------- .github/workflows/typesense-crawler-stage.yml | 11 ----------- 2 files changed, 22 deletions(-) diff --git a/.github/workflows/Algolia-crawler-stage.yml b/.github/workflows/Algolia-crawler-stage.yml index 3e7276a79..5cc0de820 100644 --- a/.github/workflows/Algolia-crawler-stage.yml +++ b/.github/workflows/Algolia-crawler-stage.yml @@ -13,17 +13,6 @@ on: # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: # This workflow contains a single job called "build" - sonarqube-analysis: - runs-on: ubuntu-latest - steps: - - name: Checkout repo - uses: actions/checkout@v2 - - - name: SonarQube Analysis - uses: SonarSource/sonarqube-scan-action@master - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build: # The type of runner that the job will run on runs-on: ubuntu-latest diff --git a/.github/workflows/typesense-crawler-stage.yml b/.github/workflows/typesense-crawler-stage.yml index 3917b296b..97a86bc01 100644 --- a/.github/workflows/typesense-crawler-stage.yml +++ b/.github/workflows/typesense-crawler-stage.yml @@ -7,17 +7,6 @@ on: - stage jobs: - sonarqube-analysis: - runs-on: ubuntu-latest - steps: - - name: Checkout repo - uses: actions/checkout@v2 - - - name: SonarQube Analysis - uses: SonarSource/sonarqube-scan-action@master - env: - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }} build: # The type of runner that the job will run on runs-on: ubuntu-latest