chore(go): update to go 1.22 (#3708)

* chore(go): update to go 1.22

* fix: install go before running codeql to fix autobild

* chore(test): explicitly set base crosscompile image

* fix(test): do not point at image with incorrect version of Go
This commit is contained in:
Gabe Kangas 2024-04-22 13:23:52 -07:00 committed by GitHub
parent ac0204104d
commit 439da013d8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 44 additions and 39 deletions

View file

@ -40,7 +40,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version: '1.21'
go-version: '1.22'
cache: true
- name: Install Google Chrome

View file

@ -9,7 +9,7 @@
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"
name: 'CodeQL'
on:
push:
@ -39,6 +39,11 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.22'
cache: true
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3

View file

@ -28,7 +28,7 @@ jobs:
- uses: actions/setup-go@v5
with:
go-version: '1.21'
go-version: '1.22'
cache: true
- uses: actions/checkout@v4
- name: golangci-lint

View file

@ -12,7 +12,7 @@ jobs:
test:
strategy:
matrix:
go-version: [1.20.x, 1.21.x]
go-version: [1.21.x, 1.22.x]
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:

View file

@ -27,7 +27,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
go-version: '1.22'
cache: true
- name: Cache node modules

View file

@ -17,7 +17,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '1.21'
go-version: '1.22'
cache: true
- name: Cache node modules

View file

@ -5,7 +5,7 @@ run:
# Define the Go version limit.
# Mainly related to generics support in go1.18.
# Default: use Go version from the go.mod file, fallback on the env var `GOVERSION`, fallback on 1.18
go: '1.21'
go: '1.22'
issues:
# The linter has a default list of ignorable errors. Turning this on will enable that list.
@ -69,7 +69,7 @@ linters-settings:
gosimple:
# Select the Go version to target. The default is '1.13'.
go: '1.21'
go: '1.22'
# https://staticcheck.io/docs/options#checks
checks: ['all']

View file

@ -95,7 +95,7 @@ The Owncast backend is a service written in Go.
1. Ensure you have prerequisites installed.
- C compiler, such as [GCC compiler](https://gcc.gnu.org/install/download.html) or a [Musl-compatible compiler](https://musl.libc.org/)
- [ffmpeg](https://ffmpeg.org/download.html)
1. Install the [Go toolchain](https://golang.org/dl/) (1.21 or above).
1. Install the [Go toolchain](https://golang.org/dl/) (1.22 or above).
1. Clone the repo. `git clone https://github.com/owncast/owncast`
1. `go run main.go` will run from the source.
1. Visit `http://yourserver:8080` to access the web interface or `http://yourserver:8080/admin` to access the admin.

2
go.mod
View file

@ -1,6 +1,6 @@
module github.com/owncast/owncast
go 1.21
go 1.22
require (
github.com/aws/aws-sdk-go v1.51.23