From b359ca565c624b8718eac79058bff0591b250d0e Mon Sep 17 00:00:00 2001 From: Mohammed Al Sahaf Date: Wed, 10 Jan 2024 21:04:11 +0300 Subject: ci/cd: use the build tag `nobadger` to exclude badgerdb (#6031) * ci/cd: use the build tag `nobadger` to exclude badgerdb * upgrade github.com/google/certificate-transparency-go@master --- .github/workflows/ci.yml | 8 +++----- .github/workflows/cross-build.yml | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to '.github') diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6ffb215ad..0bca6b4d9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -95,7 +95,7 @@ jobs: env: CGO_ENABLED: 0 run: | - go build -trimpath -ldflags="-w -s" -v + go build -tags nobdger -trimpath -ldflags="-w -s" -v - name: Publish Build Artifact uses: actions/upload-artifact@v4 @@ -112,7 +112,7 @@ jobs: # continue-on-error: true run: | # (go test -v -coverprofile=cover-profile.out -race ./... 2>&1) > test-results/test-result.out - go test -v -coverprofile="cover-profile.out" -short -race ./... + go test -tags nobadger -v -coverprofile="cover-profile.out" -short -race ./... # echo "status=$?" >> $GITHUB_OUTPUT # Relevant step if we reinvestigate publishing test/coverage reports @@ -147,7 +147,7 @@ jobs: # The environment is fresh, so there's no point in keeping accepting and adding the key. rsync -arz -e "ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null" --progress --delete --exclude '.git' . "$CI_USER"@ci-s390x.caddyserver.com:/var/tmp/"$short_sha" - ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -t "$CI_USER"@ci-s390x.caddyserver.com "cd /var/tmp/$short_sha; go version; go env; printf "\n\n";CGO_ENABLED=0 go test -v ./..." + ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -t "$CI_USER"@ci-s390x.caddyserver.com "cd /var/tmp/$short_sha; go version; go env; printf "\n\n";CGO_ENABLED=0 go test -tags nobadger -v ./..." test_result=$? # There's no need leaving the files around @@ -169,5 +169,3 @@ jobs: with: version: latest args: check - env: - TAG: ${{ steps.vars.outputs.version_tag }} diff --git a/.github/workflows/cross-build.yml b/.github/workflows/cross-build.yml index 5b032aab8..4abfccbc7 100644 --- a/.github/workflows/cross-build.yml +++ b/.github/workflows/cross-build.yml @@ -68,7 +68,7 @@ jobs: continue-on-error: true working-directory: ./cmd/caddy run: | - GOOS=$GOOS GOARCH=$GOARCH go build -trimpath -o caddy-"$GOOS"-$GOARCH 2> /dev/null + GOOS=$GOOS GOARCH=$GOARCH go build -tags nobadger -trimpath -o caddy-"$GOOS"-$GOARCH 2> /dev/null if [ $? -ne 0 ]; then echo "::warning ::$GOOS Build Failed" exit 0 -- cgit v1.2.3