Skip to content

Commit 90a33dc

Browse files
fclairambclaude
andauthored
chore(ci): add release-please, semantic-pr, and fix CI issues (#1578)
- Fix goreleaser Go version by using go-version-file: go.mod - Fix docker workflow to use go-version-file and add attestations permissions - Add semantic-pr workflow for PR title validation - Add release-please workflow for automated releases - Add release-please config files Note: GHCR push requires manual package settings configuration. Go to https://github.com/users/fclairamb/packages/container/ftpserver/settings and under "Manage Actions access", add the ftpserver repository with Write access. Co-authored-by: Claude Opus 4.5 <[email protected]>
1 parent 2ff5e33 commit 90a33dc

File tree

6 files changed

+86
-1
lines changed

6 files changed

+86
-1
lines changed

.github/workflows/docker.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ on:
1111
permissions:
1212
contents: read
1313
packages: write
14+
attestations: write
15+
id-token: write
1416

1517
jobs:
1618
build-and-push:
@@ -26,7 +28,7 @@ jobs:
2628
- name: Setup go
2729
uses: actions/[email protected]
2830
with:
29-
go-version: 1.25
31+
go-version-file: go.mod
3032
- name: Change version
3133
run: |
3234
curl -L https://github.com/fclairamb/ci-info/releases/download/v0.4.4/ci-info_0.4.4_linux_amd64.tar.gz | tar -zx

.github/workflows/goreleaser.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ jobs:
1717
-
1818
name: Set up Go
1919
uses: actions/[email protected]
20+
with:
21+
go-version-file: go.mod
2022
-
2123
name: Run GoReleaser
2224
uses: goreleaser/[email protected]
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Release Please
2+
3+
on:
4+
push:
5+
branches: [main]
6+
7+
permissions:
8+
contents: write
9+
pull-requests: write
10+
11+
jobs:
12+
release-please:
13+
runs-on: ubuntu-24.04
14+
steps:
15+
- uses: googleapis/[email protected]
16+
with:
17+
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/semantic-pr.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Lint PR
2+
3+
on:
4+
pull_request_target:
5+
types:
6+
- opened
7+
- reopened
8+
- edited
9+
10+
permissions:
11+
pull-requests: read
12+
13+
jobs:
14+
main:
15+
name: Validate PR title
16+
runs-on: ubuntu-24.04
17+
steps:
18+
- uses: amannn/[email protected]
19+
env:
20+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
21+
with:
22+
scopes: |
23+
config
24+
server
25+
deps
26+
docs
27+
ci
28+
fs
29+
s3
30+
gdrive
31+
dropbox
32+
gcs
33+
sftp
34+
mail
35+
telegram
36+
keycloak
37+
docker
38+
release
39+
requireScope: false

.release-please-manifest.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
".": "0.15.1"
3+
}

release-please-config.json

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
3+
"release-type": "go",
4+
"include-component-in-tag": false,
5+
"include-v-in-tag": true,
6+
"changelog-sections": [
7+
{ "type": "feat", "section": "Features" },
8+
{ "type": "fix", "section": "Bug Fixes" },
9+
{ "type": "perf", "section": "Performance Improvements" },
10+
{ "type": "revert", "section": "Reverts" },
11+
{ "type": "docs", "section": "Documentation", "hidden": true },
12+
{ "type": "style", "section": "Styles", "hidden": true },
13+
{ "type": "chore", "section": "Miscellaneous Chores", "hidden": true },
14+
{ "type": "refactor", "section": "Code Refactoring", "hidden": true },
15+
{ "type": "test", "section": "Tests", "hidden": true },
16+
{ "type": "build", "section": "Build System", "hidden": true },
17+
{ "type": "ci", "section": "Continuous Integration", "hidden": true }
18+
],
19+
"packages": {
20+
".": {}
21+
}
22+
}

0 commit comments

Comments
 (0)