Skip to content

Commit d819332

Browse files
Use go 1.20.6 in 2.7 branch (#10028)
Signed-off-by: Michel Hollands <[email protected]>
1 parent 22dc65b commit d819332

24 files changed

+58
-58
lines changed

.drone/drone.jsonnet

+1-1
Original file line numberDiff line numberDiff line change
@@ -453,7 +453,7 @@ local manifest_ecr(apps, archs) = pipeline('manifest-ecr') {
453453

454454
[
455455
pipeline('loki-build-image') {
456-
local build_image_tag = '0.28.1',
456+
local build_image_tag = '0.29.3-golangci.1.51.2',
457457
workspace: {
458458
base: '/src',
459459
path: 'loki',

.drone/drone.yml

+20-20
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ steps:
1010
dry_run: true
1111
repo: grafana/loki-build-image
1212
tags:
13-
- 0.28.1
13+
- 0.29.3-golangci.1.51.2
1414
when:
1515
event:
1616
- pull_request
@@ -26,7 +26,7 @@ steps:
2626
from_secret: docker_password
2727
repo: grafana/loki-build-image
2828
tags:
29-
- 0.28.1
29+
- 0.29.3-golangci.1.51.2
3030
username:
3131
from_secret: docker_username
3232
when:
@@ -93,14 +93,14 @@ steps:
9393
depends_on:
9494
- clone
9595
environment: {}
96-
image: grafana/loki-build-image:0.28.1
96+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
9797
name: check-drone-drift
9898
- commands:
9999
- make BUILD_IN_CONTAINER=false check-generated-files
100100
depends_on:
101101
- clone
102102
environment: {}
103-
image: grafana/loki-build-image:0.28.1
103+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
104104
name: check-generated-files
105105
- commands:
106106
- cd ..
@@ -109,23 +109,23 @@ steps:
109109
depends_on:
110110
- clone
111111
environment: {}
112-
image: grafana/loki-build-image:0.28.1
112+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
113113
name: clone-main
114114
- commands:
115115
- make BUILD_IN_CONTAINER=false test
116116
depends_on:
117117
- clone
118118
- clone-main
119119
environment: {}
120-
image: grafana/loki-build-image:0.28.1
120+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
121121
name: test
122122
- commands:
123123
- cd ../loki-main
124124
- BUILD_IN_CONTAINER=false make test
125125
depends_on:
126126
- clone-main
127127
environment: {}
128-
image: grafana/loki-build-image:0.28.1
128+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
129129
name: test-main
130130
- commands:
131131
- make BUILD_IN_CONTAINER=false compare-coverage old=../loki-main/test_results.txt
@@ -135,7 +135,7 @@ steps:
135135
- test
136136
- test-main
137137
environment: {}
138-
image: grafana/loki-build-image:0.28.1
138+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
139139
name: compare-coverage
140140
- commands:
141141
- pull=$(echo $CI_COMMIT_REF | awk -F '/' '{print $3}')
@@ -148,15 +148,15 @@ steps:
148148
TOKEN:
149149
from_secret: github_token
150150
USER: grafanabot
151-
image: grafana/loki-build-image:0.28.1
151+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
152152
name: report-coverage
153153
- commands:
154154
- make BUILD_IN_CONTAINER=false lint
155155
depends_on:
156156
- clone
157157
- check-generated-files
158158
environment: {}
159-
image: grafana/loki-build-image:0.28.1
159+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
160160
name: lint
161161
- commands:
162162
- make BUILD_IN_CONTAINER=false check-mod
@@ -165,7 +165,7 @@ steps:
165165
- test
166166
- lint
167167
environment: {}
168-
image: grafana/loki-build-image:0.28.1
168+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
169169
name: check-mod
170170
- commands:
171171
- apk add make bash && make lint-scripts
@@ -177,21 +177,21 @@ steps:
177177
- clone
178178
- check-generated-files
179179
environment: {}
180-
image: grafana/loki-build-image:0.28.1
180+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
181181
name: loki
182182
- commands:
183183
- make BUILD_IN_CONTAINER=false validate-example-configs
184184
depends_on:
185185
- loki
186186
environment: {}
187-
image: grafana/loki-build-image:0.28.1
187+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
188188
name: validate-example-configs
189189
- commands:
190190
- make BUILD_IN_CONTAINER=false check-example-config-doc
191191
depends_on:
192192
- clone
193193
environment: {}
194-
image: grafana/loki-build-image:0.28.1
194+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
195195
name: check-example-config-doc
196196
trigger:
197197
ref:
@@ -218,7 +218,7 @@ steps:
218218
depends_on:
219219
- clone
220220
environment: {}
221-
image: grafana/loki-build-image:0.28.1
221+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
222222
name: loki-mixin-check
223223
trigger:
224224
ref:
@@ -238,7 +238,7 @@ steps:
238238
depends_on:
239239
- clone
240240
environment: {}
241-
image: grafana/loki-build-image:0.28.1
241+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
242242
name: documentation-helm-reference-check
243243
trigger:
244244
ref:
@@ -1371,15 +1371,15 @@ steps:
13711371
NFPM_SIGNING_KEY:
13721372
from_secret: gpg_private_key
13731373
NFPM_SIGNING_KEY_FILE: /drone/src/private-key.key
1374-
image: grafana/loki-build-image:0.28.1
1374+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
13751375
name: write-key
13761376
- commands:
13771377
- make BUILD_IN_CONTAINER=false packages
13781378
environment:
13791379
NFPM_PASSPHRASE:
13801380
from_secret: gpg_passphrase
13811381
NFPM_SIGNING_KEY_FILE: /drone/src/private-key.key
1382-
image: grafana/loki-build-image:0.28.1
1382+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
13831383
name: test packaging
13841384
- commands:
13851385
- ./tools/packaging/verify-deb-install.sh
@@ -1405,7 +1405,7 @@ steps:
14051405
NFPM_PASSPHRASE:
14061406
from_secret: gpg_passphrase
14071407
NFPM_SIGNING_KEY_FILE: /drone/src/private-key.key
1408-
image: grafana/loki-build-image:0.28.1
1408+
image: grafana/loki-build-image:0.29.3-golangci.1.51.2
14091409
name: publish
14101410
when:
14111411
event:
@@ -1650,6 +1650,6 @@ kind: secret
16501650
name: gpg_private_key
16511651
---
16521652
kind: signature
1653-
hmac: 06ac36350b73d572bde514274c89c07dfe1a5033aa1df817072fbd4f24948f0e
1653+
hmac: 8e19cc1c8614108f3176d159a4a31d5db0af0a7cd06e8cfb04efbebdb86e5e4f
16541654

16551655
...

Makefile

+1-2
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,11 @@ DOCKER_IMAGE_DIRS := $(patsubst %/Dockerfile,%,$(DOCKERFILES))
2727
BUILD_IN_CONTAINER ?= true
2828

2929
# ensure you run `make drone` after changing this
30-
BUILD_IMAGE_VERSION := 0.28.1
30+
BUILD_IMAGE_VERSION := 0.29.3-golangci.1.51.2
3131

3232
# Docker image info
3333
IMAGE_PREFIX ?= grafana
3434

35-
FETCH_TAGS :=$(shell ./tools/fetch-tags)
3635
IMAGE_TAG := $(shell ./tools/image-tag)
3736

3837
# Version info for binaries

clients/cmd/docker-driver/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
ARG BUILD_IMAGE=grafana/loki-build-image:0.28.1
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
22
# Directories in this file are referenced from the root of the project not this folder
33
# This file is intended to be called from the root like so:
44
# docker build -t grafana/loki -f cmd/loki/Dockerfile .

clients/cmd/fluent-bit/Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
FROM golang:1.19.5 as build
1+
FROM golang:1.20.6@sha256:832f2f74baa3e2b00ace688cb2fa934dffeade39f5b4c0cc8b1cff8d3fb084a0 AS builder
22
COPY . /src/loki
33
WORKDIR /src/loki
44
RUN make clean && make BUILD_IN_CONTAINER=false fluent-bit-plugin
55

66
FROM fluent/fluent-bit:1.8
7-
COPY --from=build /src/loki/clients/cmd/fluent-bit/out_grafana_loki.so /fluent-bit/bin
7+
COPY --from=builder /src/loki/clients/cmd/fluent-bit/out_grafana_loki.so /fluent-bit/bin
88
COPY clients/cmd/fluent-bit/fluent-bit.conf /fluent-bit/etc/fluent-bit.conf
99
EXPOSE 2020
1010
CMD ["/fluent-bit/bin/fluent-bit", "-e","/fluent-bit/bin/out_grafana_loki.so", "-c", "/fluent-bit/etc/fluent-bit.conf"]

clients/cmd/promtail/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3-bullseye as build
1+
FROM golang:1.20.6-bullseye as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

clients/cmd/promtail/Dockerfile.arm32

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3-bullseye as build
1+
FROM golang:1.20.6-bullseye as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

clients/cmd/promtail/Dockerfile.cross

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
ARG BUILD_IMAGE=grafana/loki-build-image:0.28.1
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
22
# Directories in this file are referenced from the root of the project not this folder
33
# This file is intended to be called from the root like so:
44
# docker build -t grafana/promtail -f clients/cmd/promtail/Dockerfile .
5-
FROM golang:1.20.3-alpine as goenv
5+
FROM golang:1.20.6-alpine as goenv
66
RUN go env GOARCH > /goarch && \
77
go env GOARM > /goarm
88

clients/cmd/promtail/Dockerfile.debug

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# This file is intended to be called from the root like so:
33
# docker build -t grafana/promtail -f clients/cmd/promtail/Dockerfile.debug .
44

5-
FROM grafana/loki-build-image:0.28.1 as build
5+
FROM grafana/loki-build-image:0.29.3-golangci.1.51.2 as build
66
ARG GOARCH="amd64"
77
COPY . /src/loki
88
WORKDIR /src/loki

cmd/logcli/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

cmd/logql-analyzer/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

cmd/loki-canary/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

cmd/loki-canary/Dockerfile.cross

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
ARG BUILD_IMAGE=grafana/loki-build-image:0.28.1
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
22
# Directories in this file are referenced from the root of the project not this folder
33
# This file is intended to be called from the root like so:
44
# docker build -t grafana/promtail -f cmd/promtail/Dockerfile .
5-
FROM golang:1.20.3-alpine as goenv
5+
FROM golang:1.20.6-alpine as goenv
66
RUN go env GOARCH > /goarch && \
77
go env GOARM > /goarm
88

cmd/loki/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

cmd/loki/Dockerfile.cross

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
ARG BUILD_IMAGE=grafana/loki-build-image:0.28.1
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
22
# Directories in this file are referenced from the root of the project not this folder
33
# This file is intended to be called from the root like so:
44
# docker build -t grafana/loki -f cmd/loki/Dockerfile .
5-
FROM golang:1.20.3-alpine as goenv
5+
FROM golang:1.20.6-alpine as goenv
66
RUN go env GOARCH > /goarch && \
77
go env GOARM > /goarm
88

cmd/loki/Dockerfile.debug

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
12
# Directories in this file are referenced from the root of the project not this folder
23
# This file is intended to be called from the root like so:
34
# docker build -t grafana/loki -f cmd/loki/Dockerfile.debug .
45

5-
FROM golang:1.20.3-alpine as goenv
6+
FROM golang:1.20.6-alpine as goenv
67
RUN go env GOARCH > /goarch && \
78
go env GOARM > /goarm && \
89
go install github.com/go-delve/delve/cmd/dlv@latest

cmd/migrate/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22
COPY . /src/loki
33
WORKDIR /src/loki
44
RUN make clean && make BUILD_IN_CONTAINER=false migrate

cmd/querytee/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM golang:1.20.3 as build
1+
FROM golang:1.20.6 as build
22

33
COPY . /src/loki
44
WORKDIR /src/loki

cmd/querytee/Dockerfile.cross

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
ARG BUILD_IMAGE=grafana/loki-build-image:0.28.1
1+
ARG BUILD_IMAGE=grafana/loki-build-image:0.29.3-golangci.1.51.2
22
# Directories in this file are referenced from the root of the project not this folder
33
# This file is intended to be called from the root like so:
44
# docker build -t grafana/promtail -f cmd/promtail/Dockerfile .
5-
FROM golang:1.20.3-alpine as goenv
5+
FROM golang:1.20.6-alpine as goenv
66
RUN go env GOARCH > /goarch && \
77
go env GOARM > /goarm
88

loki-build-image/Dockerfile

+9-9
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# See ../docs/sources/maintaining/release-loki-build-image.md
66

77
# Install helm (https://helm.sh/) and helm-docs (https://github.com/norwoodj/helm-docs) for generating Helm Chart reference.
8-
FROM golang:1.20.3 as helm
8+
FROM golang:1.20.6-bullseye as helm
99
ARG HELM_VER="v3.2.3"
1010
RUN curl -L -o /tmp/helm-$HELM_VER.tgz https://get.helm.sh/helm-${HELM_VER}-linux-amd64.tar.gz && \
1111
tar -xz -C /tmp -f /tmp/helm-$HELM_VER.tgz && \
@@ -38,7 +38,7 @@ RUN apk add --no-cache docker-cli
3838
# TODO this should be fixed to download and extract the specific release binary from github as we do for golangci and helm above
3939
# however we need a commit which hasn't been released yet: https://github.com/drone/drone-cli/commit/1fad337d74ca0ecf420993d9d2d7229a1c99f054
4040
# Read the comment below regarding GO111MODULE=on and why it is necessary
41-
FROM golang:1.20.3 as drone
41+
FROM golang:1.20.6-bullseye as drone
4242
RUN curl -L https://github.com/drone/drone-cli/releases/download/v1.4.0/drone_linux_amd64.tar.gz | tar zx && \
4343
install -t /usr/local/bin drone
4444

@@ -47,32 +47,32 @@ RUN curl -L https://github.com/drone/drone-cli/releases/download/v1.4.0/drone_li
4747
# Error:
4848
# github.com/fatih/[email protected] requires golang.org/x/[email protected]
4949
# (not golang.org/x/[email protected] from golang.org/x/tools/cmd/goyacc@58d531046acdc757f177387bc1725bfa79895d69)
50-
FROM golang:1.20.3 as faillint
50+
FROM golang:1.20.6-bullseye as faillint
5151
RUN GO111MODULE=on go install github.com/fatih/[email protected]
5252

53-
FROM golang:1.20.3 as delve
53+
FROM golang:1.20.6-bullseye as delve
5454
RUN GO111MODULE=on go install github.com/go-delve/delve/cmd/dlv@latest
5555

5656
# Install ghr used to push binaries and template the release
5757
# This collides with the version of go tools used in the base image, thus we install it in its own image and copy it over.
58-
FROM golang:1.20.3 as ghr
58+
FROM golang:1.20.6-bullseye as ghr
5959
RUN GO111MODULE=on go install github.com/tcnksm/ghr@9349474
6060

6161
# Install nfpm (https://nfpm.goreleaser.com) for creating .deb and .rpm packages.
62-
FROM golang:1.20.3 as nfpm
62+
FROM golang:1.20.6-bullseye as nfpm
6363
RUN GO111MODULE=on go install github.com/goreleaser/nfpm/v2/cmd/[email protected]
6464

6565
# Install gotestsum
66-
FROM golang:1.20.3 as gotestsum
66+
FROM golang:1.20.6-bullseye as gotestsum
6767
RUN GO111MODULE=on go install gotest.tools/[email protected]
6868

6969
# Install tools used to compile jsonnet.
70-
FROM golang:1.20.3 as jsonnet
70+
FROM golang:1.20.6-bullseye as jsonnet
7171
RUN GO111MODULE=on go install github.com/jsonnet-bundler/jsonnet-bundler/cmd/[email protected]
7272
RUN GO111MODULE=on go install github.com/monitoring-mixins/mixtool/cmd/mixtool@bca3066
7373
RUN GO111MODULE=on go install github.com/google/go-jsonnet/cmd/[email protected]
7474

75-
FROM golang:1.20.3-buster
75+
FROM golang:1.20.6-bullseye
7676
RUN apt-get update && \
7777
apt-get install -qy \
7878
musl gnupg ragel \

operator/Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Build the manager binary
2-
FROM golang:1.20.3 as builder
2+
FROM golang:1.20.6 as builder
33

44
WORKDIR /workspace
55
# Copy the Go Modules manifests

0 commit comments

Comments
 (0)