Skip to content

Commit b8afca6

Browse files
committed
Restrict permissions, update actions
The actions release numbers were taken from the 3.1dev branch. Note: there was one strange codespell error in PR #2263. Maybe the updated action will avoid this in the future.
1 parent abdd51d commit b8afca6

3 files changed

Lines changed: 19 additions & 12 deletions

File tree

.github/workflows/codespell.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
---
22
name: Codespell
33
on: [push, pull_request]
4+
permissions:
5+
contents: read
6+
47
jobs:
58
codespell:
69
name: Check for spelling errors
710
runs-on: ubuntu-latest
811
steps:
9-
- uses: actions/checkout@v2
12+
- uses: actions/checkout@v3
1013
- uses: codespell-project/actions-codespell@master
1114
with:
1215
skip: ca_hashes.txt,tls_data.txt,*.pem,OPENSSL-LICENSE.txt

.github/workflows/docker-3.0.yml

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: docker-3.0
22

33
on:
44
push:
5-
branches:
5+
branches:
66
- 3.0
77
workflow_dispatch:
88
schedule:
@@ -19,36 +19,36 @@ jobs:
1919

2020
steps:
2121
- name: Source checkout
22-
uses: actions/checkout@v2.3.4
23-
22+
uses: actions/checkout@v3
23+
2424
- name: Setup QEMU
2525
id: qemu
26-
uses: docker/setup-qemu-action@v1.2.0
27-
26+
uses: docker/setup-qemu-action@v2.1.0
27+
2828
- name: Setup Buildx
2929
id: buildx
30-
uses: docker/setup-buildx-action@v1
30+
uses: docker/setup-buildx-action@v2
3131

3232
- name: Set Docker metadata
3333
id: docker_meta
34-
uses: docker/metadata-action@v3
34+
uses: docker/metadata-action@v4
3535
with:
3636
images: ${{ github.repository }}
3737
labels: |
3838
org.opencontainers.image.version=${{ env.BUILD_VERSION }}
3939
org.opencontainers.image.revision=${{ github.sha }}
4040
org.opencontainers.image.title=${{ github.repository }}
41-
41+
4242
- name: GitHub login
4343
if: ${{ github.event_name != 'pull_request' }}
44-
uses: docker/login-action@v1.10.0
44+
uses: docker/login-action@v2.1.0
4545
with:
4646
registry: ghcr.io
4747
username: ${{ github.actor }}
4848
password: ${{ secrets.GITHUB_TOKEN }}
4949

5050
- name: Build and push
51-
uses: docker/build-push-action@v2.6.1
51+
uses: docker/build-push-action@v3.2.0
5252
with:
5353
push: ${{ github.event_name != 'pull_request' }}
5454
context: .
@@ -60,3 +60,4 @@ jobs:
6060
labels: ${{ steps.docker_meta.outputs.labels }}
6161
tags: |
6262
ghcr.io/${{ github.repository }}:${{ env.BUILD_VERSION }}
63+
ghcr.io/${{ github.repository }}:latest

.github/workflows/test.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,9 @@ on:
2323
- 'LICENSE'
2424
- 'Dockerfile'
2525

26+
permissions:
27+
contents: read
28+
2629
jobs:
2730
build:
2831
runs-on: ${{ matrix.os }}
@@ -32,7 +35,7 @@ jobs:
3235
perl: ['5.26']
3336
name: Perl ${{ matrix.perl }} on ${{ matrix.os }}
3437
steps:
35-
- uses: actions/checkout@v2
38+
- uses: actions/checkout@v3
3639
- name: Set up perl
3740
uses: shogo82148/actions-setup-perl@v1
3841
with:

0 commit comments

Comments
 (0)