Skip to content

Commit f2b6b9d

Browse files
Starosdevclaude
andcommitted
ci: update GitHub Actions to latest versions and fix issues
- ci.yaml: - Update actions/checkout from v2 to v4 - Update actions/setup-go from v3 to v5 - Update codecov/codecov-action from v2 to v5 - Fix artifact naming conflict (coverage-frontend, coverage-backend) - Remove .zip suffix from artifact names (handled by upload-artifact) - release-frontend.yaml: - Update actions/checkout from v2 to v4 - Replace deprecated actions/upload-release-asset with softprops/action-gh-release - Add explicit permissions for contents:write 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent 865aaea commit f2b6b9d

File tree

2 files changed

+28
-23
lines changed

2 files changed

+28
-23
lines changed

.github/workflows/ci.yaml

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ jobs:
88
runs-on: ubuntu-latest
99
steps:
1010
- name: Checkout
11-
uses: actions/checkout@v2
11+
uses: actions/checkout@v4
1212
- name: Test Frontend
1313
run: |
1414
make binary-frontend-test-coverage
1515
- name: Upload coverage
1616
uses: actions/upload-artifact@v4
1717
with:
18-
name: coverage
18+
name: coverage-frontend
1919
path: ${{ github.workspace }}/webapp/frontend/coverage/lcov.info
2020
retention-days: 1
2121
test-backend:
@@ -44,14 +44,14 @@ jobs:
4444
add-apt-repository ppa:git-core/ppa && apt-get update && apt-get install -y git
4545
git --version
4646
- name: Checkout
47-
uses: actions/checkout@v2
47+
uses: actions/checkout@v4
4848
- name: Test Backend
4949
run: |
5050
make binary-clean binary-test-coverage
5151
- name: Upload coverage
5252
uses: actions/upload-artifact@v4
5353
with:
54-
name: coverage
54+
name: coverage-backend
5555
path: ${{ github.workspace }}/coverage.txt
5656
retention-days: 1
5757
test-coverage:
@@ -62,13 +62,17 @@ jobs:
6262
runs-on: ubuntu-latest
6363
steps:
6464
- name: Checkout
65-
uses: actions/checkout@v2
66-
- name: Download coverage reports
65+
uses: actions/checkout@v4
66+
- name: Download backend coverage
6767
uses: actions/download-artifact@v4
6868
with:
69-
name: coverage
69+
name: coverage-backend
70+
- name: Download frontend coverage
71+
uses: actions/download-artifact@v4
72+
with:
73+
name: coverage-frontend
7074
- name: Upload coverage reports
71-
uses: codecov/codecov-action@v2
75+
uses: codecov/codecov-action@v5
7276
with:
7377
files: ${{ github.workspace }}/coverage.txt,${{ github.workspace }}/lcov.info
7478
flags: unittests
@@ -98,17 +102,18 @@ jobs:
98102
- { on: windows-latest, goos: windows, goarch: arm64 }
99103
steps:
100104
- name: Checkout
101-
uses: actions/checkout@v2
102-
- uses: actions/setup-go@v3
105+
uses: actions/checkout@v4
106+
- name: Setup Go
107+
uses: actions/setup-go@v5
103108
with:
104-
go-version: '^1.20.1'
109+
go-version: '1.20'
105110
- name: Build Binaries
106111
run: |
107112
make binary-clean binary-all
108113
- name: Archive
109114
uses: actions/upload-artifact@v4
110115
with:
111-
name: binaries-${{ matrix.cfg.on }}-${{ matrix.cfg.goos }}-${{ matrix.cfg.goarch }}-${{ matrix.cfg.goarm || 'na' }}.zip
116+
name: binaries-${{ matrix.cfg.on }}-${{ matrix.cfg.goos }}-${{ matrix.cfg.goarch }}-${{ matrix.cfg.goarm || 'na' }}
112117
path: |
113118
scrutiny-web-*
114119
scrutiny-collector-metrics-*

.github/workflows/release-frontend.yaml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,30 +5,30 @@ on:
55
release:
66
# Only use the types keyword to narrow down the activity types that will trigger your workflow.
77
types: [published]
8+
9+
permissions:
10+
contents: write
11+
812
jobs:
913
release-frontend:
1014
name: Release Frontend
1115
runs-on: ubuntu-latest
1216
container: node:lts-slim
1317
steps:
1418
- name: Checkout
15-
uses: actions/checkout@v2
19+
uses: actions/checkout@v4
1620
with:
17-
ref: ${{github.event.release.tag_name}}
18-
- name: "Generate frontend version information"
19-
run: "cd webapp/frontend && ./git.version.sh"
21+
ref: ${{ github.event.release.tag_name }}
22+
- name: Generate frontend version information
23+
run: cd webapp/frontend && ./git.version.sh
2024
- name: Build Frontend
2125
run: |
2226
apt-get update && apt-get install -y make
2327
make binary-frontend
2428
tar -czf scrutiny-web-frontend.tar.gz dist
2529
- name: Upload Frontend Asset
26-
id: upload-release-asset3
27-
uses: actions/upload-release-asset@v1
30+
uses: softprops/action-gh-release@v2
31+
with:
32+
files: scrutiny-web-frontend.tar.gz
2833
env:
2934
GITHUB_TOKEN: ${{ secrets.SCRUTINY_GITHUB_TOKEN }}
30-
with:
31-
upload_url: ${{ github.event.release.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
32-
asset_path: './scrutiny-web-frontend.tar.gz'
33-
asset_name: scrutiny-web-frontend.tar.gz
34-
asset_content_type: application/gzip

0 commit comments

Comments
 (0)