-
Notifications
You must be signed in to change notification settings - Fork 0
#151: addressing Aquasec findings #152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
19dc598
c868101
68a2895
3cd8a5f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,31 @@ | ||
| version: 2 | ||
| updates: | ||
| - package-ecosystem: "github-actions" | ||
| directory: "/" | ||
| target-branch: "master" | ||
| schedule: | ||
| interval: "weekly" | ||
| day: "sunday" | ||
| labels: | ||
| - "auto update" | ||
| - "infrastructure" | ||
| - "no RN" | ||
| open-pull-requests-limit: 3 | ||
| commit-message: | ||
| prefix: "chore" | ||
| include: "scope" | ||
|
|
||
| - package-ecosystem: "sbt" | ||
| directory: "/" | ||
| target-branch: "master" | ||
| schedule: | ||
| interval: "weekly" | ||
| day: "sunday" | ||
| labels: | ||
| - "auto update" | ||
| - "dependencies" | ||
| - "no RN" | ||
| open-pull-requests-limit: 3 | ||
| commit-message: | ||
| prefix: "chore" | ||
| include: "scope" |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -49,50 +49,59 @@ jobs: | |
|
|
||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
| uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 | ||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Setup Scala | ||
| uses: olafurpg/setup-scala@v14 | ||
| uses: olafurpg/setup-scala@32ffa16635ff8f19cc21ea253a987f0fdf29844c | ||
| with: | ||
| java-version: "adopt@1.8" | ||
|
|
||
| - name: Prepare testing database | ||
| run: sbt flywayMigrate | ||
|
|
||
| - name: Build and run tests | ||
| continue-on-error: true | ||
| id: jacocorun | ||
| run: sbt ++${{env.scalaLong}} jacoco | ||
|
|
||
| - name: Add coverage to PR (core) | ||
| if: steps.jacocorun.outcome == 'success' | ||
| id: jacoco-core | ||
| uses: madrapps/jacoco-report@v1.6.1 | ||
| uses: madrapps/jacoco-report@50d3aff4548aa991e6753342d9ba291084e63848 | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: cd .github/workflows && cat jacoco_report.yml | head -100Repository: AbsaOSS/fa-db Length of output: 3585 🏁 Script executed: sed -n '60,105p' .github/workflows/jacoco_report.ymlRepository: AbsaOSS/fa-db Length of output: 2157 JaCoCo report action pinned to commit SHA. All three jacoco-report steps consistently use the same commit SHA (50d3aff4548aa991e6753342d9ba291084e63848). Pinning to a specific commit SHA ensures the exact, immutable version of the action's code is used, with a commit SHA uniquely identifying a specific state of the repository. Add a comment indicating which version the SHA corresponds to (e.g., 🤖 Prompt for AI Agents |
||
| with: | ||
| paths: ${{ github.workspace }}/core/target/scala-${{ env.scalaShort }}/jacoco/report/jacoco.xml | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| min-coverage-overall: ${{ env.coverage-overall }} | ||
| min-coverage-changed-files: ${{ env.coverage-changed-files }} | ||
| title: JaCoCo `core` module code coverage report - scala ${{ env.scalaLong }} | ||
| update-comment: true | ||
|
|
||
| - name: Add coverage to PR (doobie) | ||
| if: steps.jacocorun.outcome == 'success' | ||
| id: jacoco-doobie | ||
| uses: madrapps/jacoco-report@v1.6.1 | ||
| uses: madrapps/jacoco-report@50d3aff4548aa991e6753342d9ba291084e63848 | ||
| with: | ||
| paths: ${{ github.workspace }}/doobie/target/scala-${{ env.scalaShort }}/jacoco/report/jacoco.xml | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| min-coverage-overall: ${{ env.coverage-overall }} | ||
| min-coverage-changed-files: ${{ env.coverage-changed-files }} | ||
| title: JaCoCo `doobie` module code coverage report - scala ${{ env.scalaLong }} | ||
| update-comment: true | ||
|
|
||
| - name: Add coverage to PR (slick) | ||
| if: steps.jacocorun.outcome == 'success' | ||
| id: jacoco-slick | ||
| uses: madrapps/jacoco-report@v1.6.1 | ||
| uses: madrapps/jacoco-report@50d3aff4548aa991e6753342d9ba291084e63848 | ||
| with: | ||
| paths: ${{ github.workspace }}/slick/target/scala-${{ env.scalaShort }}/jacoco/report/jacoco.xml | ||
| token: ${{ secrets.GITHUB_TOKEN }} | ||
| min-coverage-overall: ${{env.coverage-overall }} | ||
| min-coverage-changed-files: ${{ env.coverage-changed-files }} | ||
| title: JaCoCo `slick` module code coverage report - scala ${{ env.scalaLong }} | ||
| update-comment: true | ||
|
|
||
| - name: Get the Coverage info | ||
| if: steps.jacocorun.outcome == 'success' | ||
| run: | | ||
|
|
@@ -102,9 +111,10 @@ jobs: | |
| echo "Changed Files coverage ${{ steps.jacoco-doobie.outputs.coverage-changed-files }}" | ||
| echo "Total `slick` module coverage ${{ steps.jacoco-slick.outputs.coverage-overall }}" | ||
| echo "Changed Files coverage ${{ steps.jacoco-slick.outputs.coverage-changed-files }}" | ||
|
|
||
| - name: Fail PR if changed files coverage is less than ${{ env.coverage-changed-files }}% | ||
| if: steps.jacocorun.outcome == 'success' | ||
| uses: actions/github-script@v6 | ||
| uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd | ||
| with: | ||
| script: | | ||
| const coverageCheckFailed = | ||
|
|
@@ -114,9 +124,10 @@ jobs: | |
| if (coverageCheckFailed) { | ||
| core.setFailed('Changed files coverage is less than ${{ env.coverage-changed-files }}%!'); | ||
| } | ||
|
|
||
| - name: Fail PR if overall files coverage is less than ${{ env.coverage-overall }}% | ||
| if: ${{ (steps.jacocorun.outcome == 'success') && (env.check-overall-coverages == 'true') }} | ||
| uses: actions/github-script@v6 | ||
| uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd | ||
| with: | ||
| script: | | ||
| const coverageCheckFailed = | ||
|
|
@@ -126,9 +137,10 @@ jobs: | |
| if (coverageCheckFailed) { | ||
| core.setFailed('Overall coverage is less than ${{ env.coverage-overall }}%!'); | ||
| } | ||
|
|
||
| - name: Edit JaCoCo comments on build failure | ||
| if: steps.jacocorun.outcome != 'success' | ||
| uses: actions/github-script@v6 | ||
| uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd | ||
| with: | ||
| script: | | ||
| const issue_number = context.issue.number; | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The z0al/dependent-issues action is from a repository archived by the owner on Sep 26, 2023. While pinning to a commit SHA is a security best practice, using an action from an archived repository introduces maintenance and security risks since it is now read-only. Consider migrating to an actively maintained alternative for issue dependency management.
🤖 Prompt for AI Agents