From 8191f24ef3bfed320db7efa9e57f5f682fb861b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jakub=20Soko=C5=82owski?= Date: Tue, 26 Jul 2022 12:42:19 +0200 Subject: [PATCH] docker: upgrade Golang version to 1.18 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Otherwise it fails with: ``` build github.com/status-im/status-go/cmd/statusd: cannot load github.com/lucas-clemente/quic-go/internal/qtls: no Go source files ``` We also add missing `g++` compiler for `go-libutp` to fix: ``` go build github.com/anacrolix/go-libutp: g++: exec: "g++": executable file not found in $PATH ``` As well as install `libgcc` and `libstdc++` to avoids failures like this: ``` Error loading shared library libstdc++.so.6: No such file or directory (needed by /usr/local/bin/statusd) Error loading shared library libgcc_s.so.1: No such file or directory (needed by /usr/local/bin/statusd) Error relocating /usr/local/bin/statusd: _Znwm: symbol not found Error relocating /usr/local/bin/statusd: _ZdlPvm: symbol not found Error relocating /usr/local/bin/statusd: _Unwind_Resume: symbol not found Error relocating /usr/local/bin/statusd: __gxx_personality_v0: symbol not found ``` Signed-off-by: Jakub SokoĊ‚owski --- _assets/build/Dockerfile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/_assets/build/Dockerfile b/_assets/build/Dockerfile index dce76ddb3..c9fee1d6a 100644 --- a/_assets/build/Dockerfile +++ b/_assets/build/Dockerfile @@ -1,7 +1,7 @@ # Build status-go in a Go builder container -FROM golang:1.13-alpine as builder +FROM golang:1.18-alpine as builder -RUN apk add --no-cache make gcc musl-dev linux-headers +RUN apk add --no-cache make gcc g++ musl-dev linux-headers ARG build_tags ARG build_flags @@ -18,7 +18,7 @@ LABEL maintainer="support@status.im" LABEL source="https://github.com/status-im/status-go" LABEL description="status-go is an underlying part of Status - a browser, messenger, and gateway to a decentralized world." -RUN apk add --no-cache ca-certificates bash +RUN apk add --no-cache ca-certificates bash libgcc libstdc++ RUN mkdir -p /static/keys COPY --from=builder /go/src/github.com/status-im/status-go/build/bin/statusd /usr/local/bin/