tortoise icon indicating copy to clipboard operation
tortoise copied to clipboard

`make install` fails with kustomize error due to patchesStrategicMerge

Open GarupanOjisan opened this issue 9 months ago • 0 comments

What

When running make install, I encountered the following error related to kustomize:

Error: invalid Kustomization: json: cannot unmarshal object into Go struct field Kustomization.patchesStrategicMerge of type types.PatchStrategicMerge
error: no objects passed to apply
make: *** [install] Error 1

The issue seems to originate from this file: https://github.com/mercari/tortoise/blob/09688416fc8b37772c5be313c65fedc5c330a262/config/crd/kustomization.yaml#L8-L19

Possibly, the path: fields under each entry in patchesStrategicMerge are unnecessary, and also, these entries should likely be commented out by default.

Environment:

MacOS 15.3.1 Kustomize v5.4.3

Steps to Reproduce:

make install

Full output

mkdir -p /Users/user/dev/tortoise/bin
Downloading sigs.k8s.io/controller-tools/cmd/[email protected]
go: downloading sigs.k8s.io/controller-tools v0.16.1
go: downloading k8s.io/api v0.31.0
go: downloading k8s.io/apimachinery v0.31.0
go: downloading github.com/gobuffalo/flect v1.0.2
go: downloading k8s.io/apiextensions-apiserver v0.31.0
go: downloading k8s.io/utils v0.0.0-20240711033017-18e509b52bc8
go: downloading golang.org/x/sync v0.8.0
go: downloading golang.org/x/sys v0.23.0
go: downloading golang.org/x/net v0.28.0
go: downloading golang.org/x/text v0.17.0
/Users/user/dev/tortoise/bin/controller-gen rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
Downloading sigs.k8s.io/kustomize/kustomize/[email protected]
/Users/user/dev/tortoise/bin/kustomize build config/crd | kubectl apply -f -
Error: invalid Kustomization: json: cannot unmarshal object into Go struct field Kustomization.patchesStrategicMerge of type types.PatchStrategicMerge
error: no objects passed to apply
make: *** [install] Error 1

GarupanOjisan avatar Mar 11 '25 07:03 GarupanOjisan