Skip to content

Commit 5dea464

Browse files
authored
resolve some github actions workflow security issues (#755)
1 parent 1dfea70 commit 5dea464

File tree

2 files changed

+15
-14
lines changed

2 files changed

+15
-14
lines changed

.github/workflows/onedpl.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
# SPDX-License-Identifier: BSD-3-Clause
44

55
name: "oneDPL"
6+
permissions: read-all
67

78
on:
89
workflow_dispatch:
@@ -18,9 +19,9 @@ jobs:
1819
CXX: icpx
1920
CTEST_OUTPUT_ON_FAILURE: 1
2021
steps:
21-
- uses: actions/checkout@v4
22+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
2223
- name: Checkout Distributed Ranges branch in oneDPL
23-
uses: actions/checkout@v4
24+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
2425
with:
2526
repository: oneapi-src/oneDPL
2627
ref: distributed-ranges
@@ -38,7 +39,7 @@ jobs:
3839
. /opt/intel/oneapi/setvars.sh
3940
ctest --test-dir dr/build -L SHP -j 4
4041
# srun -p cluster dr/scripts/run_command_on_compute_node.sh dr/build/Testing/tests.outerr.txt ctest --test-dir dr/build -L TESTLABEL -j 4
41-
- uses: actions/upload-artifact@v4
42+
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
4243
if: always()
4344
with:
4445
name: log-pvc-impi-icpx

.github/workflows/pr.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@ jobs:
2121
runs-on: intel-ubuntu-latest
2222
timeout-minutes: 10
2323
steps:
24-
- uses: actions/checkout@v4
24+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
2525
- name: Ubuntu dependencies
2626
run: scripts/install-doxygen.sh
27-
- uses: actions/setup-python@v5
27+
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
2828
with:
2929
python-version: '3.10'
3030
cache: 'pip'
@@ -47,7 +47,7 @@ jobs:
4747
env:
4848
CXX: ${{ matrix.cxx }}
4949
steps:
50-
- uses: actions/checkout@v4
50+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
5151
- name: Generate
5252
run: cmake -B build
5353
- name: Build
@@ -56,7 +56,7 @@ jobs:
5656
run: ctest --test-dir build -L MHP -j 4
5757
- name: SHP unit tests
5858
run: ctest --test-dir build -L SHP -j 4
59-
- uses: actions/upload-artifact@v4
59+
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
6060
if: always()
6161
with:
6262
name: log-gcc-${{ env.CXX }}
@@ -82,7 +82,7 @@ jobs:
8282
CXX: icpx
8383
FI_PROVIDER: tcp
8484
steps:
85-
- uses: actions/checkout@v4
85+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
8686
- name: Generate
8787
run: cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config }}
8888
- name: Save environment dump
@@ -91,7 +91,7 @@ jobs:
9191
run: cmake --build build --target all-tests -- -j
9292
- name: Unit tests
9393
run: srun -p cluster scripts/run_command_on_compute_node.sh build/Testing/tests.outerr.txt ctest --test-dir build -L TESTLABEL -j 4
94-
- uses: actions/upload-artifact@v4
94+
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
9595
if: always()
9696
with:
9797
name: log-pvc-impi-icpx-${{ matrix.config }}
@@ -121,7 +121,7 @@ jobs:
121121
env:
122122
CXX: icpx
123123
steps:
124-
- uses: actions/checkout@v4
124+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
125125
- name: Generate
126126
run: cmake -B build -DCMAKE_BUILD_TYPE=${{ matrix.config }} -DENABLE_ISHMEM=on -DENABLE_L0=on -DENABLE_OFI=on -DOFI_PROVIDER=psm3
127127
- name: Build ISHMEM
@@ -130,7 +130,7 @@ jobs:
130130
run: cmake --build build --target mhp-tests mhp-tests-3 -- -j
131131
- name: MHP unit tests
132132
run: srun -p cluster scripts/run_command_on_compute_node.sh build/Testing/mhptests.outerr.txt ctest --test-dir build -R ^mhp-tests-sycl -L MHP -j 4
133-
- uses: actions/upload-artifact@v4
133+
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
134134
if: always()
135135
with:
136136
name: log-ishmem-impi-icpx-${{ matrix.config }}
@@ -150,8 +150,8 @@ jobs:
150150
SPHINXOPTS: -q -W
151151
if: ${{ github.ref == 'refs/heads/main' }}
152152
steps:
153-
- uses: actions/checkout@v4
154-
- uses: actions/setup-python@v5
153+
- uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
154+
- uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
155155
with:
156156
python-version: '3.10'
157157
cache: 'pip'
@@ -162,7 +162,7 @@ jobs:
162162
run: |
163163
make -C doc/spec html
164164
- name: Checkout gh-pages
165-
uses: actions/checkout@v4
165+
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
166166
with:
167167
ref: gh-pages
168168
path: gh-pages

0 commit comments

Comments
 (0)