Skip to content

Commit d8d2722

Browse files
author
Dusan Malusev
committed
feature(go1.24): update to the new go version 1.24
Signed-off-by: Dusan Malusev <[email protected]>
1 parent add6719 commit d8d2722

33 files changed

+2357
-355
lines changed

.dockerignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
dist/
2+
bin/
3+
setup.sh
4+

.github/workflows/build-base.yml

Lines changed: 0 additions & 25 deletions
This file was deleted.

.github/workflows/build.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

.github/workflows/docker.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Docker Build
2+
3+
on:
4+
workflow_call:
5+
inputs:
6+
version:
7+
required: true
8+
type: string
9+
workflow_dispatch:
10+
inputs:
11+
version:
12+
default: ""
13+
required: true
14+
type: string
15+
16+
jobs:
17+
docker-build:
18+
runs-on: ubuntu-24.04
19+
steps:
20+
- name: Checkout
21+
uses: actions/checkout@v4
22+
with:
23+
fetch-depth: 0
24+
25+
# Needed for ARM64 Docker builds
26+
- name: Set up QEMU
27+
uses: docker/setup-qemu-action@v3
28+
29+
- name: Set up Docker Buildx
30+
uses: docker/setup-buildx-action@v3
31+
32+
- name: Login to dockerhub
33+
uses: docker/login-action@v3
34+
with:
35+
username: ${{ secrets.DOCKERHUB_USERNAME }}
36+
password: ${{ secrets.DOCKERHUB_TOKEN }}
37+
- name: Build and push API
38+
uses: docker/build-push-action@v6
39+
with:
40+
file: ./Dockerfile
41+
context: .
42+
push: true
43+
pull: true
44+
platforms: 'linux/amd64,linux/arm64/v8'
45+
target: production
46+
cache-from: type=gha
47+
cache-to: type=gha,mode=max
48+
tags: codeLieutenant/gofiber-boilerplate:${{ inputs.version }}

.github/workflows/go.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Go
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
paths:
7+
- "app/**"
8+
- "main.go"
9+
branches:
10+
- master
11+
pull_request:
12+
paths:
13+
- "app/**"
14+
- "main.go"
15+
branches:
16+
- master
17+
18+
jobs:
19+
build:
20+
name: Lint Test and Build
21+
runs-on: ubuntu-24.04
22+
steps:
23+
- name:
24+
uses: actions/checkout@v4
25+
- name: Setup Go
26+
uses: actions/setup-go@v5
27+
with:
28+
go-version: '1.24'
29+
- name: Install Task
30+
uses: arduino/setup-task@v1
31+
with:
32+
version: 3.x
33+
repo-token: ${{ secrets.GITHUB_TOKEN }}
34+
- name: Set up gotestfmt
35+
uses: GoTestTools/gotestfmt-action@v2
36+
with:
37+
repo: gotestfmt
38+
- name: Build
39+
run: task build
40+
- name: golangci-lint
41+
uses: reviewdog/action-golangci-lint@v2
42+
with:
43+
golangci_lint_flags: "--tests=false"
44+
- name: Unit Tests
45+
run: |
46+
cp config.example.yml config.yml
47+
task test

.github/workflows/lint.yml

Lines changed: 0 additions & 26 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: goreleaser
2+
3+
on:
4+
push:
5+
tags:
6+
- "*"
7+
8+
permissions:
9+
contents: write
10+
packages: write
11+
issues: write
12+
id-token: write
13+
14+
jobs:
15+
goreleaser:
16+
runs-on: ubuntu-24.04
17+
steps:
18+
- name: Checkout
19+
uses: actions/checkout@v4
20+
with:
21+
fetch-depth: 0
22+
23+
- name: Set up Go
24+
uses: actions/setup-go@v5
25+
with:
26+
go-version: '1.24'
27+
28+
# Needed for ARM64 Docker builds
29+
- name: Set up QEMU
30+
uses: docker/setup-qemu-action@v3
31+
32+
- name: Set up Docker Buildx
33+
uses: docker/setup-buildx-action@v3
34+
35+
- name: Login to dockerhub
36+
uses: docker/login-action@v3
37+
with:
38+
username: ${{ secrets.DOCKERHUB_USERNAME }}
39+
password: ${{ secrets.DOCKERHUB_TOKEN }}
40+
41+
- name: Run GoReleaser
42+
uses: goreleaser/goreleaser-action@v6
43+
with:
44+
distribution: goreleaser
45+
version: "v2.5"
46+
args: release --clean
47+
env:
48+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/setup-test.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
name: Setup Script Test
2+
3+
on:
4+
push:
5+
paths:
6+
- "setup.sh"
7+
branches:
8+
- master
9+
pull_request:
10+
paths:
11+
- "setup.sh"
12+
branches:
13+
- master
14+
15+
jobs:
16+
build:
17+
name: Run setup script
18+
runs-on: ubuntu-24.04
19+
steps:
20+
- name:
21+
uses: actions/checkout@v4
22+

.github/workflows/test.yml

Lines changed: 0 additions & 39 deletions
This file was deleted.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ bin/
88
tmp/
99
.idea/
1010
*.log
11+
dist/

0 commit comments

Comments
 (0)