Bump libgit2 image to v0.3.0
Signed-off-by: Paulo Gomes <paulo.gomes@weave.works>
This commit is contained in:
parent
ac80849d29
commit
1ab76264de
12
Dockerfile
12
Dockerfile
|
|
@ -3,7 +3,7 @@ ARG GO_VERSION=1.19
|
||||||
ARG XX_VERSION=1.1.2
|
ARG XX_VERSION=1.1.2
|
||||||
|
|
||||||
ARG LIBGIT2_IMG=ghcr.io/fluxcd/golang-with-libgit2-only
|
ARG LIBGIT2_IMG=ghcr.io/fluxcd/golang-with-libgit2-only
|
||||||
ARG LIBGIT2_TAG=v0.2.0
|
ARG LIBGIT2_TAG=v0.3.0
|
||||||
|
|
||||||
FROM ${LIBGIT2_IMG}:${LIBGIT2_TAG} AS libgit2-libs
|
FROM ${LIBGIT2_IMG}:${LIBGIT2_TAG} AS libgit2-libs
|
||||||
|
|
||||||
|
|
@ -64,11 +64,11 @@ ENV CGO_ENABLED=1
|
||||||
|
|
||||||
# Instead of using xx-go, (cross) compile with vanilla go leveraging musl tool chain.
|
# Instead of using xx-go, (cross) compile with vanilla go leveraging musl tool chain.
|
||||||
RUN export PKG_CONFIG_PATH="/usr/local/$(xx-info triple)/lib/pkgconfig" && \
|
RUN export PKG_CONFIG_PATH="/usr/local/$(xx-info triple)/lib/pkgconfig" && \
|
||||||
export CGO_LDFLAGS="$(pkg-config --static --libs --cflags libgit2) -static -fuse-ld=lld" && \
|
export CGO_LDFLAGS="$(pkg-config --static --libs --cflags libgit2) -static -fuse-ld=lld" && \
|
||||||
xx-go build \
|
xx-go build \
|
||||||
-ldflags "-s -w" \
|
-ldflags "-s -w" \
|
||||||
-tags 'netgo,osusergo,static_build' \
|
-tags 'netgo,osusergo,static_build' \
|
||||||
-o /source-controller -trimpath main.go;
|
-o /source-controller -trimpath main.go;
|
||||||
|
|
||||||
# Ensure that the binary was cross-compiled correctly to the target platform.
|
# Ensure that the binary was cross-compiled correctly to the target platform.
|
||||||
RUN xx-verify --static /source-controller
|
RUN xx-verify --static /source-controller
|
||||||
|
|
|
||||||
2
Makefile
2
Makefile
|
|
@ -4,7 +4,7 @@ TAG ?= latest
|
||||||
|
|
||||||
# Base image used to build the Go binary
|
# Base image used to build the Go binary
|
||||||
LIBGIT2_IMG ?= ghcr.io/fluxcd/golang-with-libgit2-only
|
LIBGIT2_IMG ?= ghcr.io/fluxcd/golang-with-libgit2-only
|
||||||
LIBGIT2_TAG ?= v0.2.0
|
LIBGIT2_TAG ?= v0.3.0
|
||||||
|
|
||||||
# Allows for defining additional Go test args, e.g. '-tags integration'.
|
# Allows for defining additional Go test args, e.g. '-tags integration'.
|
||||||
GO_TEST_ARGS ?= -race
|
GO_TEST_ARGS ?= -race
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@
|
||||||
|
|
||||||
set -euxo pipefail
|
set -euxo pipefail
|
||||||
|
|
||||||
LIBGIT2_TAG="${LIBGIT2_TAG:-v0.2.0}"
|
LIBGIT2_TAG="${LIBGIT2_TAG:-v0.3.0}"
|
||||||
GOPATH="${GOPATH:-/root/go}"
|
GOPATH="${GOPATH:-/root/go}"
|
||||||
GO_SRC="${GOPATH}/src"
|
GO_SRC="${GOPATH}/src"
|
||||||
PROJECT_PATH="github.com/fluxcd/source-controller"
|
PROJECT_PATH="github.com/fluxcd/source-controller"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue