Skip to content

Commit 6648d03

Browse files
authored
[StepSecurity] Apply security best practices
Added a step to harden the runner by auditing outbound calls in multiple jobs.
1 parent 885025d commit 6648d03

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

.github/workflows/ci.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,10 @@ jobs:
1818
environment:
1919
name: code_quality
2020
steps:
21+
- name: Harden the runner (Audit all outbound calls)
22+
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
23+
with:
24+
egress-policy: audit
2125
- name: Checkout repository
2226
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
2327
- name: Install Nix
@@ -36,6 +40,10 @@ jobs:
3640
environment:
3741
name: code_quality
3842
steps:
43+
- name: Harden the runner (Audit all outbound calls)
44+
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
45+
with:
46+
egress-policy: audit
3947
- name: Checkout repository
4048
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
4149
with:
@@ -63,6 +71,10 @@ jobs:
6371
environment:
6472
name: build
6573
steps:
74+
- name: Harden the runner (Audit all outbound calls)
75+
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
76+
with:
77+
egress-policy: audit
6678
- name: Checkout repository
6779
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
6880
- name: Install Nix
@@ -97,6 +109,10 @@ jobs:
97109
url: ${{ steps.deployment.outputs.page_url }}
98110
if: github.event_name != 'pull_request'
99111
steps:
112+
- name: Harden the runner (Audit all outbound calls)
113+
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
114+
with:
115+
egress-policy: audit
100116
- name: Deploy to GitHub Pages
101117
id: deployment
102118
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5

0 commit comments

Comments
 (0)