Skip to content

Commit

Permalink
Try fix licenses check
Browse files Browse the repository at this point in the history
  • Loading branch information
josvazg committed Sep 30, 2024
1 parent a4e13e4 commit edb93f6
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ ATLAS_KEY_SECRET_NAME = mongodb-atlas-operator-api-key

BASE_GO_PACKAGE = github.com/mongodb/mongodb-atlas-kubernetes/v2
GO_LICENSES = go-licenses
GO_LICENSES_VERSION = 1.6.0
KUSTOMIZE = kustomize
DISALLOWED_LICENSES = restricted,reciprocal

Expand Down Expand Up @@ -145,8 +146,10 @@ licenses-up-to-date: ## Check if the licenses.csv is up to date
check-licenses: licenses-up-to-date ## Check licenses are compliant with our restrictions
@echo "Checking licenses not to be: $(DISALLOWED_LICENSES)"
@echo "============================================"
# https://github.com/google/go-licenses/issues/244
GOTOOLCHAIN=local GOOS=linux GOARCH=amd64 $(GO_LICENSES) check --include_tests \
go get github.com/google/[email protected]
export GOOS=linux
export GOARCH=amd64
$(go env GOROOT)/bin/go run github.com/google/$(GO_LICENSES)@v$(GO_LICENSES_VERSION) check --include_tests \
--disallowed_types $(DISALLOWED_LICENSES) $(BASE_GO_PACKAGE)/...
@echo "--------------------"
@echo "Licenses check: PASS"
Expand Down

0 comments on commit edb93f6

Please sign in to comment.