-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #87 from step-security-bot/stepsecurity_remediatio…
…n_1724860935 [StepSecurity] ci: Harden GitHub Actions
- Loading branch information
Showing
2 changed files
with
10 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,10 +28,10 @@ jobs: | |
egress-policy: audit | ||
|
||
- name: Check out the commit | ||
uses: actions/checkout@v4 | ||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
uses: actions/setup-python@39cd14951b08e74b54015e9e001cdefcf80e669f # v5.1.1 | ||
with: | ||
python-version: ~${{ matrix.version }} | ||
|
||
|
@@ -48,14 +48,14 @@ jobs: | |
run: python3 -m pip install . | ||
|
||
- name: Test with pytest | ||
uses: nick-fields/retry@v3 | ||
uses: nick-fields/retry@7152eba30c6575329ac0576536151aca5a72780e # v3.0.0 | ||
with: | ||
timeout_minutes: 10 | ||
max_attempts: 3 | ||
command: python3 -m pytest --verbose --cov=shell_logger test/ | ||
|
||
- name: Upload coverage reports to Codecov | ||
uses: codecov/codecov-action@v4 | ||
uses: codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673 # v4.5.0 | ||
env: | ||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | ||
|
||
|
@@ -66,7 +66,7 @@ jobs: | |
working-directory: ./doc | ||
|
||
- name: Archive documentation coverage results | ||
uses: actions/upload-artifact@v4 | ||
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6 | ||
with: | ||
name: docs-coverage-report-${{ matrix.version }} | ||
path: docs-coverage-report-${{ matrix.version }}.txt | ||
|
@@ -83,7 +83,7 @@ jobs: | |
egress-policy: audit | ||
|
||
- name: Conventional Commits | ||
uses: taskmedia/[email protected] | ||
uses: taskmedia/action-conventional-commits@866c0e6dba6aaaef9ad0939a40620b27888906c2 # v1.1.17 | ||
with: | ||
types: > | ||
build|chore|ci|docs|feat|fix|minor|patch|perf|style|refactor|test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -29,12 +29,12 @@ jobs: | |
egress-policy: audit | ||
|
||
- name: "Checkout code" | ||
uses: actions/checkout@v4 | ||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | ||
with: | ||
persist-credentials: false | ||
|
||
- name: "Run analysis" | ||
uses: ossf/[email protected] | ||
uses: ossf/scorecard-action@62b2cac7ed8198b15735ed49ab1e5cf35480ba46 # v2.4.0 | ||
with: | ||
results_file: results.sarif | ||
results_format: sarif | ||
|
@@ -46,13 +46,13 @@ jobs: | |
publish_results: true | ||
|
||
- name: "Upload artifact" | ||
uses: actions/upload-artifact@v4 | ||
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6 | ||
with: | ||
name: SARIF file | ||
path: results.sarif | ||
retention-days: 5 | ||
|
||
- name: "Upload to code-scanning dashboard" | ||
uses: github/codeql-action/upload-sarif@v3 | ||
uses: github/codeql-action/upload-sarif@2c779ab0d087cd7fe7b826087247c2c81f27bfa6 # v3.26.5 | ||
with: | ||
sarif_file: results.sarif |