Skip to content

Commit

Permalink
Upgrade golang to 1.21
Browse files Browse the repository at this point in the history
  • Loading branch information
raoptimus committed Dec 19, 2023
1 parent 0bb95d4 commit 34d67ae
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 7 deletions.
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ PKG_WORKDIR = "${BUILD_DIR}/${PKG_NAME}-${VERSION}"
DOCKER_ID_USER = raoptimus
DOCKER_PASS ?= ""
DOCKER_IMAGE = "${PKG_NAME}"
export GO_IMAGE_VERSION="1.21"

help: ## Show help message
@cat $(MAKEFILE_LIST) | grep -e "^[a-zA-Z_\-]*: *.*## *" | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
Expand All @@ -38,6 +39,7 @@ build-docker-image:
--build-arg GIT_BRANCH=${GIT_BRANCH} \
--build-arg GIT_COMMIT=${GIT_COMMIT} \
--build-arg GIT_TAG=${GIT_TAG} \
--build-arg GO_IMAGE_VERSION=${GO_IMAGE_VERSION} \
-f ./docker/image/build/Dockerfile \
-t ${DOCKER_ID_USER}/${DOCKER_IMAGE}:"${VERSION}-alpine" \
-t ${DOCKER_ID_USER}/${DOCKER_IMAGE}:latest ./
Expand Down
5 changes: 3 additions & 2 deletions docker/image/build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
FROM golang:1.19-alpine3.16 as build
ARG GO_IMAGE_VERSION
FROM golang:${GO_IMAGE_VERSION}-alpine as build

RUN apk add --update make git bash file
RUN apk add --update make bash file

WORKDIR /go/src/db-migrator
COPY . ./
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/raoptimus/db-migrator.go

go 1.20
go 1.21

require (
github.com/ClickHouse/clickhouse-go v1.5.4
Expand Down
2 changes: 1 addition & 1 deletion pkg/console/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/raoptimus/db-migrator.go/pkg/console

go 1.20
go 1.21
2 changes: 1 addition & 1 deletion pkg/iohelp/go.mod
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module github.com/raoptimus/db-migrator.go/pkg/iohelp

go 1.20
go 1.21

require github.com/pkg/errors v0.9.1
2 changes: 1 addition & 1 deletion pkg/sqlio/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/raoptimus/db-migrator.go/pkg/sqlio

go 1.20
go 1.21

require github.com/stretchr/testify v1.8.3

Expand Down
2 changes: 1 addition & 1 deletion pkg/timex/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/raoptimus/db-migrator.go/pkg/timex

go 1.20
go 1.21

0 comments on commit 34d67ae

Please sign in to comment.