Skip to content

Commit 1cd712e

Browse files
authored
Drop harden-runner (#1115)
Sadly, the host names aren't entirely predictable and we're getting spurious failures & warnings.
1 parent c7308a6 commit 1cd712e

File tree

4 files changed

+3
-102
lines changed

4 files changed

+3
-102
lines changed

.github/workflows/build-docset.yml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,24 +10,19 @@ env:
1010
PIP_DISABLE_PIP_VERSION_CHECK: 1
1111
PIP_NO_PYTHON_VERSION_WARNING: 1
1212

13-
permissions: # added using https://github.com/step-security/secure-workflows
13+
permissions:
1414
contents: read
1515

1616
jobs:
1717
docset:
1818
runs-on: ubuntu-latest
1919
steps:
20-
- name: Harden Runner
21-
uses: step-security/harden-runner@v2
22-
with:
23-
egress-policy: audit # TODO: change to 'egress-policy: block' after couple of runs
24-
2520
- uses: actions/checkout@v3
2621
with:
27-
fetch-depth: 0 # get correct version once we switch to hatch-vcs
22+
fetch-depth: 0
2823
- uses: actions/setup-python@v4
2924
with:
30-
python-version: "3.11"
25+
python-version: "3.x"
3126

3227
- run: pip install tox
3328

.github/workflows/ci.yml

Lines changed: 0 additions & 59 deletions
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,6 @@ jobs:
4444
${{ contains(matrix.python-version, '~') && true || false }}
4545
4646
steps:
47-
- name: Harden Runner
48-
uses: step-security/harden-runner@v2
49-
with:
50-
egress-policy: block
51-
allowed-endpoints: >
52-
api.github.com:443
53-
files.pythonhosted.org:443
54-
github.com:443
55-
objects.githubusercontent.com:443
56-
pypi.org:443
5747
- uses: actions/checkout@v3
5848
- uses: actions/setup-python@v4
5949
with:
@@ -90,16 +80,6 @@ jobs:
9080
needs: tests
9181

9282
steps:
93-
- name: Harden Runner
94-
uses: step-security/harden-runner@v2
95-
with:
96-
egress-policy: block
97-
allowed-endpoints: >
98-
files.pythonhosted.org:443
99-
github.com:443
100-
pypi.org:443
101-
api.github.com:443
102-
10383
- uses: actions/checkout@v3
10484
- uses: actions/setup-python@v4
10585
with:
@@ -130,16 +110,6 @@ jobs:
130110
name: Build docs & run doctests
131111
runs-on: ubuntu-latest
132112
steps:
133-
- name: Harden Runner
134-
uses: step-security/harden-runner@v2
135-
with:
136-
egress-policy: block
137-
allowed-endpoints: >
138-
docs.python.org:443
139-
files.pythonhosted.org:443
140-
github.com:443
141-
pypi.org:443
142-
143113
- uses: actions/checkout@v3
144114
- uses: actions/setup-python@v4
145115
with:
@@ -175,18 +145,6 @@ jobs:
175145
name: Check types using pyright
176146
runs-on: ubuntu-latest
177147
steps:
178-
- name: Harden Runner
179-
uses: step-security/harden-runner@v2
180-
with:
181-
egress-policy: block
182-
allowed-endpoints: >
183-
files.pythonhosted.org:443
184-
github.com:443
185-
nodejs.org:443
186-
pypi.org:443
187-
registry.npmjs.org:443
188-
api.github.com:443
189-
190148
- uses: actions/checkout@v3
191149
- uses: actions/setup-python@v4
192150
with:
@@ -203,16 +161,6 @@ jobs:
203161
os: [ubuntu-latest, windows-latest]
204162

205163
steps:
206-
- name: Harden Runner
207-
uses: step-security/harden-runner@v2
208-
with:
209-
disable-sudo: true
210-
egress-policy: block
211-
allowed-endpoints: >
212-
files.pythonhosted.org:443
213-
github.com:443
214-
pypi.org:443
215-
api.github.com:443
216164
- uses: actions/checkout@v3
217165
- uses: actions/setup-python@v4
218166
with:
@@ -235,13 +183,6 @@ jobs:
235183
runs-on: ubuntu-latest
236184

237185
steps:
238-
- name: Harden Runner
239-
uses: step-security/harden-runner@v2
240-
with:
241-
disable-sudo: true
242-
egress-policy: block
243-
allowed-endpoints: >
244-
api.github.com:443
245186
- name: Decide whether the needed jobs succeeded or failed
246187
uses: re-actors/alls-green@release/v1
247188
with:

.github/workflows/codeql-analysis.yml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -27,18 +27,6 @@ jobs:
2727
language: ["python"]
2828

2929
steps:
30-
- name: Harden Runner
31-
uses: step-security/harden-runner@v2
32-
with:
33-
egress-policy: block
34-
allowed-endpoints: >
35-
api.github.com:443
36-
bootstrap.pypa.io:443
37-
files.pythonhosted.org:443
38-
github.com:443
39-
pypi.org:443
40-
uploads.github.com:443
41-
4230
- name: Checkout repository
4331
uses: actions/checkout@v3
4432

.github/workflows/pypi-package.yml

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,6 @@ jobs:
2222
runs-on: ubuntu-latest
2323

2424
steps:
25-
- uses: step-security/harden-runner@v2
26-
with:
27-
disable-sudo: true
28-
egress-policy: block
29-
allowed-endpoints: >
30-
files.pythonhosted.org:443
31-
github.com:443
32-
pypi.org:443
33-
3425
- uses: actions/checkout@v3
3526
with:
3627
fetch-depth: 0
@@ -46,13 +37,6 @@ jobs:
4637
needs: build-package
4738

4839
steps:
49-
- uses: step-security/harden-runner@v2
50-
with:
51-
disable-sudo: true
52-
egress-policy: block
53-
allowed-endpoints: >
54-
test.pypi.org:443
55-
5640
- name: Download packages built by build-and-inspect-python-package
5741
uses: actions/download-artifact@v3
5842
with:
@@ -74,13 +58,6 @@ jobs:
7458
needs: build-package
7559

7660
steps:
77-
- uses: step-security/harden-runner@v2
78-
with:
79-
disable-sudo: true
80-
egress-policy: block
81-
allowed-endpoints: >
82-
upload.pypi.org:443
83-
8461
- name: Download packages built by build-and-inspect-python-package
8562
uses: actions/download-artifact@v3
8663
with:

0 commit comments

Comments
 (0)