@@ -6,13 +6,11 @@ SHELL = /bin/bash
66# version is moved to a separate repo and release process.
77export IMAGE_VERSION = v1.31.0
88# Build-time variables to inject into binaries
9- export SIMPLE_VERSION = $(shell (test "$(shell git describe --tags) " = "$(shell git describe --tags --abbrev=0) " && echo $(shell git describe --tags) ) || echo $(shell git describe --tags --abbrev=0) +git)
10- export GIT_VERSION = $(shell git describe --dirty --tags --always)
11- export GIT_COMMIT = $(shell git rev-parse HEAD)
9+ # export SIMPLE_VERSION = $(shell (test "$(shell git describe --tags)" = "$(shell git describe --tags --abbrev=0)" && echo $(shell git describe --tags)) || echo $(shell git describe --tags --abbrev=0)+git)
10+ # export GIT_VERSION = $(shell git describe --dirty --tags --always)
11+ # export GIT_COMMIT = $(shell git rev-parse HEAD)
1212export K8S_VERSION = 1.26.0
1313
14- export OPERATOR_SDK_VERSION = $(IMAGE_VERSION )
15-
1614# Build settings
1715export TOOLS_DIR = tools/bin
1816export SCRIPTS_DIR = tools/scripts
@@ -37,9 +35,9 @@ export PATH := $(PWD)/$(BUILD_DIR):$(PWD)/$(TOOLS_DIR):$(PATH)
3735# #@ Development
3836
3937.PHONY : generate
40- generate : operator-sdk build # Generate CLI docs and samples
38+ generate : build # Generate CLI docs and samples
4139 rm -rf testdata
42- go run ./hack/generate/samples/generate_testdata.go --bin $( OPERATOR_SDK )
40+ go run ./hack/generate/samples/generate_testdata.go
4341 go generate ./...
4442
4543.PHONY : fix
@@ -142,11 +140,12 @@ e2e_targets := test-e2e $(e2e_tests)
142140export KIND_CLUSTER := osdk-test
143141
144142KUBEBUILDER_ASSETS = $(PWD ) /$(shell go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest && $(shell go env GOPATH) /bin/setup-envtest use $(K8S_VERSION ) --bin-dir tools/bin/ -p path)
145- test-e2e-setup :: operator-sdk build dev-install cluster-create
143+ test-e2e-setup :: build dev-install cluster-create
146144
147145.PHONY : cluster-create
148146cluster-create ::
149147 [[ " ` $( TOOLS_DIR) /kind get clusters` " =~ " $( KIND_CLUSTER) " ]] || $(TOOLS_DIR ) /kind create cluster --image=" kindest/node:v$( K8S_VERSION) " --name $(KIND_CLUSTER )
148+ $(TOOLS_DIR ) /kind export kubeconfig --name $(KIND_CLUSTER )
150149
151150.PHONY : dev-install
152151dev-install ::
@@ -164,29 +163,12 @@ test-e2e-teardown:
164163$(e2e_targets ) :: test-e2e-setup
165164test-e2e :: $(e2e_tests ) # # Run e2e tests
166165
167- test-e2e-ansible :: operator-sdk image/ansible-operator # # Run Ansible e2e tests
168- go test -count=1 ./internal/ansible/proxy/...
166+ test-e2e-ansible :: image/ansible-operator # # Run Ansible e2e tests
169167 go test ./test/e2e/ansible -v -ginkgo.v
170168test-e2e-ansible-molecule :: install dev-install image/ansible-operator # # Run molecule-based Ansible e2e tests
171169 go run ./hack/generate/samples/molecule/generate.go
172170 ./hack/tests/e2e-ansible-molecule.sh
173171
174- # # Location to install dependencies to
175- LOCALBIN ?= $(shell pwd) /bin
176- $(LOCALBIN ) :
177- mkdir -p $(LOCALBIN )
178-
179- .PHONY : operator-sdk
180- OPERATOR_SDK ?= $(LOCALBIN ) /operator-sdk
181- operator-sdk : # # Download operator-sdk locally if necessary.
182- @{ \
183- set -e ; \
184- mkdir -p $(dir $(OPERATOR_SDK ) ) ; \
185- OS=$(shell go env GOOS) && ARCH=$(shell go env GOARCH) && \
186- curl -sSLo $(OPERATOR_SDK ) https://github.com/operator-framework/operator-sdk/releases/download/$(OPERATOR_SDK_VERSION ) /operator-sdk_$$ {OS}_$$ {ARCH} ; \
187- chmod +x $(OPERATOR_SDK ) ; \
188- }
189-
190172.DEFAULT_GOAL := help
191173.PHONY : help
192174help : # # Show this help screen.
0 commit comments