Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
makefile: run
go mod tidy
during make generate
We have multiple go.mod files, this does not seem to agree with operator-sdk. operator-sdk will generate files and call `make generate`. However, that will then fail because we didn't call `go mod tidy` for api/ directory. Note that compared to sriov-network-operator, in dpu-operator we have several go.mod files. That does not seem to agree with operator-sdk, or at least, something is not hooked up right. Hack `make generate` to call `go mod tidy` first. Otherwise: $ git checkout -B C origin/main && \ git reset --hard HEAD && \ git clean -fdx && \ make operator-sdk && \ ./bin/operator-sdk create webhook --group config --version v1 --kind DpuOperatorConfig --defaulting --programmatic-validation branch 'C' set up to track 'origin/main'. Reset branch 'C' Your branch is up to date with 'origin/main'. HEAD is now at e58a9c9 Merge pull request #194 from thom311/th/hack-scripts-cleanup INFO[0000] Writing kustomize manifests for you to edit... ERRO[0000] Unable to find the target #- path: manager_webhook_patch.yaml to uncomment in the file config/default/kustomization.yaml. INFO[0000] Writing scaffold for you to edit... INFO[0000] api/v1/dpuoperatorconfig_webhook.go INFO[0000] api/v1/dpuoperatorconfig_webhook_test.go INFO[0000] api/v1/webhook_suite_test.go INFO[0000] Update dependencies: $ go mod tidy INFO[0000] Running make: $ make generate test -s /data/src/dpu-operator/bin/controller-gen && /data/src/dpu-operator/bin/controller-gen --version | grep -q v0.15.0 || \ GOBIN=/data/src/dpu-operator/bin GOFLAGS='' go install sigs.k8s.io/controller-tools/cmd/[email protected] GOFLAGS='' /data/src/dpu-operator/bin/controller-gen object:headerFile="hack/boilerplate.go.txt" paths="./..." Error: load packages in root "/data/src/dpu-operator/api": err: exit status 1: stderr: go: updates to go.mod needed; to update it: go mod tidy
- Loading branch information