Skip to content

Commit 7e97f06

Browse files
authored
Merge pull request #3739 from apostasie/ci-cleanup
Small Ci adjustments & cleanups
2 parents fd217a0 + 6e913a6 commit 7e97f06

File tree

7 files changed

+41
-48
lines changed

7 files changed

+41
-48
lines changed

.github/workflows/ghcr-image-build-and-publish.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -31,19 +31,19 @@ jobs:
3131

3232
steps:
3333
- name: Checkout repository
34-
uses: actions/[email protected]
34+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3535

3636
- name: Set up QEMU
37-
uses: docker/setup-qemu-action@v3
37+
uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf # v3.2.0
3838

3939
- name: Set up Docker Buildx
40-
uses: docker/setup-buildx-action@v3
40+
uses: docker/setup-buildx-action@c47758b77c9736f4b2ef4073d4d51994fabfe349 # v3.7.1
4141

4242
# Login against a Docker registry except on PR
4343
# https://github.com/docker/login-action
4444
- name: Log into registry ${{ env.REGISTRY }}
4545
if: github.event_name != 'pull_request'
46-
uses: docker/[email protected]
46+
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
4747
with:
4848
registry: ${{ env.REGISTRY }}
4949
username: ${{ github.actor }}
@@ -53,14 +53,14 @@ jobs:
5353
# https://github.com/docker/metadata-action
5454
- name: Extract Docker metadata
5555
id: meta
56-
uses: docker/[email protected]
56+
uses: docker/metadata-action@369eb591f429131d6889c46b94e711f089e6ca96 # v5.6.1
5757
with:
5858
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
5959

6060
# Build and push Docker image with Buildx (don't push on PR)
6161
# https://github.com/docker/build-push-action
6262
- name: Build and push Docker image
63-
uses: docker/[email protected]
63+
uses: docker/build-push-action@48aba3b46d1b1fec4febb7c5d0c644b249a11355 # v6.10.0
6464
with:
6565
context: .
6666
platforms: linux/amd64,linux/arm64

.github/workflows/lint.yml

+5-7
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
env:
3737
GOOS: "${{ matrix.goos }}"
3838
steps:
39-
- uses: actions/[email protected]
39+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
4040
with:
4141
fetch-depth: 1
4242
- name: Set GO env
@@ -46,28 +46,26 @@ jobs:
4646
. ./hack/build-integration-canary.sh
4747
canary::golang::latest
4848
fi
49-
- uses: actions/setup-go@v5
49+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
5050
with:
5151
go-version: ${{ env.GO_VERSION }}
5252
check-latest: true
53-
cache: true
5453
- name: golangci-lint
55-
uses: golangci/golangci-lint-action@v6
54+
uses: golangci/golangci-lint-action@774c35bcccffb734694af9e921f12f57d882ef74 # v6.1.1
5655
with:
5756
args: --verbose
5857
other:
5958
timeout-minutes: 5
6059
name: yaml | shell | imports order
6160
runs-on: ubuntu-24.04
6261
steps:
63-
- uses: actions/[email protected]
62+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
6463
with:
6564
fetch-depth: 1
66-
- uses: actions/setup-go@v5
65+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
6766
with:
6867
go-version: ${{ env.GO_VERSION }}
6968
check-latest: true
70-
cache: true
7169
- name: yaml
7270
run: make lint-yaml
7371
- name: shell

.github/workflows/project.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,15 @@ jobs:
1313
runs-on: ubuntu-24.04
1414
timeout-minutes: 20
1515
steps:
16-
- uses: actions/[email protected]
16+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1717
with:
1818
path: src/github.com/containerd/nerdctl
1919
fetch-depth: 100
20-
- uses: actions/setup-go@v5
20+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
2121
with:
2222
go-version: ${{ env.GO_VERSION }}
2323
cache-dependency-path: src/github.com/containerd/nerdctl
24-
- uses: containerd/[email protected]
24+
- uses: containerd/project-checks@434a07157608eeaa1d5c8d4dd506154204cd9401 # v1.1.0
2525
with:
2626
working-directory: src/github.com/containerd/nerdctl
2727
repo-access-token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/release.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ jobs:
1010
runs-on: ubuntu-24.04
1111
timeout-minutes: 40
1212
steps:
13-
- uses: actions/[email protected]
14-
- uses: actions/setup-go@v5
13+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
14+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
1515
with:
1616
go-version: 1.23.x
1717
- name: "Compile binaries"

.github/workflows/test-canary.yml

+4-5
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
runs-on: "ubuntu-24.04"
2020
timeout-minutes: 40
2121
steps:
22-
- uses: actions/[email protected]
22+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2323
with:
2424
fetch-depth: 1
2525
- name: "Prepare integration test environment"
@@ -55,7 +55,7 @@ jobs:
5555
run:
5656
shell: bash
5757
steps:
58-
- uses: actions/[email protected]
58+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
5959
with:
6060
fetch-depth: 1
6161
- name: Set GO env
@@ -70,16 +70,15 @@ jobs:
7070
7171
. ./hack/build-integration-canary.sh
7272
canary::golang::latest
73-
- uses: actions/setup-go@v5
73+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
7474
with:
7575
go-version: ${{ env.GO_VERSION }}
76-
cache: true
7776
check-latest: true
7877
- run: go install ./cmd/nerdctl
7978
- run: go install -v gotest.tools/gotestsum@v1
8079
# This here is solely to get the cni install script, which has not been modified in 3+ years.
8180
# There is little to no reason to update this to latest containerd
82-
- uses: actions/[email protected]
81+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
8382
with:
8483
repository: containerd/containerd
8584
ref: "v1.7.24"

.github/workflows/test-kube.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
env:
1818
ROOTFUL: true
1919
steps:
20-
- uses: actions/[email protected]
20+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
2121
with:
2222
fetch-depth: 1
2323
- name: "Run Kubernetes integration tests"

.github/workflows/test.yml

+20-24
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ jobs:
4040
CONTAINERD_VERSION: "${{ matrix.containerd }}"
4141
ARCH: "${{ matrix.arch }}"
4242
steps:
43-
- uses: actions/[email protected]
43+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
4444
with:
4545
fetch-depth: 1
4646
- name: "Expose GitHub Runtime variables for gha"
47-
uses: crazy-max/ghaction-github-runtime@v3
47+
uses: crazy-max/ghaction-github-runtime@b3a9207c0e1ef41f4cf215303c976869d0c2c1c4 # v3.0.0
4848
- name: "Build dependencies for the integration test environment image"
4949
run: |
5050
docker buildx create --name with-gha --use
@@ -73,16 +73,15 @@ jobs:
7373
- os: ubuntu-24.04
7474
goos: linux
7575
steps:
76-
- uses: actions/[email protected]
76+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
7777
with:
7878
fetch-depth: 1
79-
- uses: actions/setup-go@v5
79+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
8080
with:
8181
go-version: ${{ env.GO_VERSION }}
8282
check-latest: true
83-
cache: true
8483
- if: ${{ matrix.goos=='windows' }}
85-
uses: actions/[email protected]
84+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
8685
with:
8786
repository: containerd/containerd
8887
ref: v1.7.24
@@ -126,11 +125,11 @@ jobs:
126125
ARCH: "${{ matrix.arch }}"
127126
UBUNTU_VERSION: "${{ matrix.ubuntu }}"
128127
steps:
129-
- uses: actions/[email protected]
128+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
130129
with:
131130
fetch-depth: 1
132131
- name: "Expose GitHub Runtime variables for gha"
133-
uses: crazy-max/ghaction-github-runtime@v3
132+
uses: crazy-max/ghaction-github-runtime@b3a9207c0e1ef41f4cf215303c976869d0c2c1c4 # v3.0.0
134133
- name: "Prepare integration test environment"
135134
run: |
136135
docker buildx create --name with-gha --use
@@ -175,15 +174,15 @@ jobs:
175174
ARCH: "${{ matrix.arch }}"
176175
UBUNTU_VERSION: "${{ matrix.ubuntu }}"
177176
steps:
178-
- uses: actions/[email protected]
177+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
179178
with:
180179
fetch-depth: 1
181180
- name: Enable ipv4 and ipv6 forwarding
182181
run: |
183182
sudo sysctl -w net.ipv6.conf.all.forwarding=1
184183
sudo sysctl -w net.ipv4.ip_forward=1
185184
- name: "Expose GitHub Runtime variables for gha"
186-
uses: crazy-max/ghaction-github-runtime@v3
185+
uses: crazy-max/ghaction-github-runtime@b3a9207c0e1ef41f4cf215303c976869d0c2c1c4 # v3.0.0
187186
- name: Enable IPv6 for Docker, and configure docker to use containerd for gha
188187
run: |
189188
sudo mkdir -p /etc/docker
@@ -271,7 +270,7 @@ jobs:
271270
}
272271
EOT
273272
sudo systemctl restart apparmor.service
274-
- uses: actions/[email protected]
273+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
275274
with:
276275
fetch-depth: 1
277276
- name: "Register QEMU (tonistiigi/binfmt)"
@@ -284,7 +283,7 @@ jobs:
284283
docker run --privileged --rm tonistiigi/binfmt --install linux/arm64
285284
docker run --privileged --rm tonistiigi/binfmt --install linux/arm/v7
286285
- name: "Expose GitHub Runtime variables for gha"
287-
uses: crazy-max/ghaction-github-runtime@v3
286+
uses: crazy-max/ghaction-github-runtime@b3a9207c0e1ef41f4cf215303c976869d0c2c1c4 # v3.0.0
288287
- name: "Prepare (network driver=slirp4netns, port driver=builtin)"
289288
run: |
290289
docker buildx create --name with-gha --use
@@ -313,13 +312,12 @@ jobs:
313312
matrix:
314313
go-version: ["1.22.x", "1.23.x"]
315314
steps:
316-
- uses: actions/[email protected]
315+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
317316
with:
318317
fetch-depth: 1
319-
- uses: actions/setup-go@v5
318+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
320319
with:
321320
go-version: ${{ matrix.go-version }}
322-
cache: true
323321
check-latest: true
324322
- name: "build"
325323
run: GO_VERSION="$(echo ${{ matrix.go-version }} | sed -e s/.x//)" make binaries
@@ -329,13 +327,12 @@ jobs:
329327
name: docker
330328
runs-on: ubuntu-24.04
331329
steps:
332-
- uses: actions/[email protected]
330+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
333331
with:
334332
fetch-depth: 1
335-
- uses: actions/setup-go@v5
333+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
336334
with:
337335
go-version: ${{ env.GO_VERSION }}
338-
cache: true
339336
check-latest: true
340337
- name: "Register QEMU (tonistiigi/binfmt)"
341338
run: |
@@ -365,17 +362,16 @@ jobs:
365362
run:
366363
shell: bash
367364
steps:
368-
- uses: actions/[email protected]
365+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
369366
with:
370367
fetch-depth: 1
371-
- uses: actions/setup-go@v5
368+
- uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
372369
with:
373370
go-version: ${{ env.GO_VERSION }}
374-
cache: true
375371
check-latest: true
376372
- run: go install ./cmd/nerdctl
377373
- run: go install -v gotest.tools/gotestsum@v1
378-
- uses: actions/[email protected]
374+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
379375
with:
380376
repository: containerd/containerd
381377
ref: v1.7.24
@@ -399,10 +395,10 @@ jobs:
399395
# ubuntu-24.04 lacks the vagrant package
400396
runs-on: ubuntu-22.04
401397
steps:
402-
- uses: actions/[email protected]
398+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
403399
with:
404400
fetch-depth: 1
405-
- uses: actions/cache@v4
401+
- uses: actions/cache@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
406402
with:
407403
path: /root/.vagrant.d
408404
key: vagrant-${{ matrix.box }}

0 commit comments

Comments
 (0)