Skip to content

Commit 6c67a9e

Browse files
authored
Merge pull request #587 from supabase/chore-review-actions
ci: explicit permissions in actions
2 parents 5b10773 + f9b6592 commit 6c67a9e

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

.github/workflows/pre-commit.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ on:
33
pull_request:
44
push: { branches: [master] }
55

6+
permissions:
7+
contents: read
8+
69
jobs:
710
build:
811
runs-on: ubuntu-latest

.github/workflows/release.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,10 @@ on:
77
tags:
88
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
99

10+
permissions:
11+
contents: write
12+
id-token: write
13+
1014
jobs:
1115
release:
1216
name: Create Release
@@ -87,7 +91,7 @@ jobs:
8791
cp `find target/release -type f -name "${{ matrix.extension_name }}*"` archive
8892
8993
# name of the package directory before packaging
90-
package_dir=${{ matrix.extension_name }}-${{ github.ref_name }}-pg${{ matrix.postgres }}-${{ matrix.box.arch }}-linux-gnu
94+
package_dir="${{ matrix.extension_name }}-${{ github.ref_name }}-pg${{ matrix.postgres }}-${{ matrix.box.arch }}-linux-gnu"
9195
9296
# Copy files into directory structure
9397
mkdir -p ${package_dir}/usr/lib/postgresql/lib
@@ -110,7 +114,7 @@ jobs:
110114
cd ../../../../../..
111115
112116
# Create install control file
113-
extension_version=${{ github.ref_name }}
117+
extension_version="${{ github.ref_name }}"
114118
# strip the leading v
115119
deb_version=${extension_version:1}
116120

.github/workflows/test.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ on:
33
pull_request:
44
push: { branches: [master] }
55

6+
permissions:
7+
contents: read
8+
69
jobs:
710
test:
811
name: Run tests

0 commit comments

Comments
 (0)