File tree Expand file tree Collapse file tree 7 files changed +28
-11
lines changed Expand file tree Collapse file tree 7 files changed +28
-11
lines changed Original file line number Diff line number Diff line change 33
33
${{ runner.os }}-go
34
34
- name : Smoke test Fuzzers
35
35
run : make fuzz-smoketest
36
+ env :
37
+ SKIP_COSIGN_VERIFICATION : true
Original file line number Diff line number Diff line change 47
47
uses : fluxcd/pkg/actions/helm@main
48
48
- name : Run E2E tests
49
49
env :
50
+ SKIP_COSIGN_VERIFICATION : true
50
51
CREATE_CLUSTER : false
51
52
run : make e2e
52
53
76
77
kind create cluster --name ${{ steps.prep.outputs.CLUSTER }} --kubeconfig=/tmp/${{ steps.prep.outputs.CLUSTER }}
77
78
- name : Run e2e tests
78
79
env :
80
+ SKIP_COSIGN_VERIFICATION : true
79
81
KIND_CLUSTER_NAME : ${{ steps.prep.outputs.CLUSTER }}
80
82
KUBECONFIG : /tmp/${{ steps.prep.outputs.CLUSTER }}
81
83
CREATE_CLUSTER : false
Original file line number Diff line number Diff line change 34
34
${{ runner.os }}-go-
35
35
- name : Run tests
36
36
env :
37
+ SKIP_COSIGN_VERIFICATION : true
37
38
TEST_AZURE_ACCOUNT_NAME : ${{ secrets.TEST_AZURE_ACCOUNT_NAME }}
38
39
TEST_AZURE_ACCOUNT_KEY : ${{ secrets.TEST_AZURE_ACCOUNT_KEY }}
39
40
run : make test
51
52
go-version : 1.19.x
52
53
- name : Run tests
53
54
env :
55
+ SKIP_COSIGN_VERIFICATION : true
56
+
54
57
TEST_AZURE_ACCOUNT_NAME : ${{ secrets.TEST_AZURE_ACCOUNT_NAME }}
55
58
TEST_AZURE_ACCOUNT_KEY : ${{ secrets.TEST_AZURE_ACCOUNT_KEY }}
56
59
87
90
${{ runner.os }}-go-
88
91
- name : Run tests
89
92
run : make test
93
+ env :
94
+ SKIP_COSIGN_VERIFICATION : true
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ ARG GO_VERSION=1.19
3
3
ARG XX_VERSION=1.1.2
4
4
5
5
ARG LIBGIT2_IMG=ghcr.io/fluxcd/golang-with-libgit2-only
6
- ARG LIBGIT2_TAG=v0.2 .0
6
+ ARG LIBGIT2_TAG=v0.3 .0
7
7
8
8
FROM ${LIBGIT2_IMG}:${LIBGIT2_TAG} AS libgit2-libs
9
9
@@ -64,11 +64,11 @@ ENV CGO_ENABLED=1
64
64
65
65
# Instead of using xx-go, (cross) compile with vanilla go leveraging musl tool chain.
66
66
RUN export PKG_CONFIG_PATH="/usr/local/$(xx-info triple)/lib/pkgconfig" && \
67
- export CGO_LDFLAGS="$(pkg-config --static --libs --cflags libgit2) -static -fuse-ld=lld" && \
68
- xx-go build \
69
- -ldflags "-s -w" \
70
- -tags 'netgo,osusergo,static_build' \
71
- -o /source-controller -trimpath main.go;
67
+ export CGO_LDFLAGS="$(pkg-config --static --libs --cflags libgit2) -static -fuse-ld=lld" && \
68
+ xx-go build \
69
+ -ldflags "-s -w" \
70
+ -tags 'netgo,osusergo,static_build' \
71
+ -o /source-controller -trimpath main.go;
72
72
73
73
# Ensure that the binary was cross-compiled correctly to the target platform.
74
74
RUN xx-verify --static /source-controller
Original file line number Diff line number Diff line change @@ -4,14 +4,17 @@ TAG ?= latest
4
4
5
5
# Base image used to build the Go binary
6
6
LIBGIT2_IMG ?= ghcr.io/fluxcd/golang-with-libgit2-only
7
- LIBGIT2_TAG ?= v0.2 .0
7
+ LIBGIT2_TAG ?= v0.3 .0
8
8
9
9
# Allows for defining additional Go test args, e.g. '-tags integration'.
10
10
GO_TEST_ARGS ?= -race
11
11
12
12
# Allows for filtering tests based on the specified prefix
13
13
GO_TEST_PREFIX ?=
14
14
15
+ # Defines whether cosign verification should be skipped.
16
+ SKIP_COSIGN_VERIFICATION ?= false
17
+
15
18
# Allows for defining additional Docker buildx arguments,
16
19
# e.g. '--push'.
17
20
BUILD_ARGS ?=
Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ IMG="${IMG:-}"
6
6
TAG=" ${TAG:- } "
7
7
IMG_TAG=" ${IMG} :${TAG} "
8
8
DOWNLOAD_URL=" https://github.com/fluxcd/golang-with-libgit2/releases/download/${TAG} "
9
+ SKIP_COSIGN_VERIFICATION=" ${SKIP_COSIGN_VERIFICATION:- false} "
9
10
10
11
TMP_DIR=$( mktemp -d)
11
12
@@ -48,9 +49,13 @@ cosign_verify(){
48
49
assure_provenance () {
49
50
[[ $# -eq 1 ]] || fatal ' assure_provenance needs exactly 1 arguments'
50
51
51
- cosign_verify " ${TMP_DIR} /checksums.txt.pem" \
52
- " ${TMP_DIR} /checksums.txt.sig" \
53
- " ${TMP_DIR} /checksums.txt"
52
+ if " ${SKIP_COSIGN_VERIFICATION} " ; then
53
+ echo ' Skipping cosign verification...'
54
+ else
55
+ cosign_verify " ${TMP_DIR} /checksums.txt.pem" \
56
+ " ${TMP_DIR} /checksums.txt.sig" \
57
+ " ${TMP_DIR} /checksums.txt"
58
+ fi
54
59
55
60
pushd " ${TMP_DIR} " || exit
56
61
if command -v sha256sum; then
Original file line number Diff line number Diff line change 16
16
17
17
set -euxo pipefail
18
18
19
- LIBGIT2_TAG=" ${LIBGIT2_TAG:- v0.2 .0} "
19
+ LIBGIT2_TAG=" ${LIBGIT2_TAG:- v0.3 .0} "
20
20
GOPATH=" ${GOPATH:-/ root/ go} "
21
21
GO_SRC=" ${GOPATH} /src"
22
22
PROJECT_PATH=" github.com/fluxcd/source-controller"
You can’t perform that action at this time.
0 commit comments