Tilt: support additional kustomize file names

Created on 18 Apr 2019  Â·  1Comment  Â·  Source: tilt-dev/tilt

The main kustomize file can come in different filenames.

➜ kustomize build /tmp
Error: unable to find one of 'kustomization.yaml', 'kustomization.yml' or 'Kustomization' in directory '/tmp'

Right now tilt only looks for kustomization.yaml.
And if one tries to point to the kustomize file directly it won't work.

error: 'exit status 1'
       stdout: ''
       stderr: 'Error: got file 'Kustomization', but
       './kustomize/infrastructure/Kustomization' must be a directory to be a
        root
       '

edit: if I rename the first kustomization file it will just continue with all base resources. This makes tilt unusable for us right now (can't rename all kustomization files).

bug

Most helpful comment

Hi @fentas thanks for the report! I'll fix this. In the meantime you can run kustomize by hand with a local (for more info see the Custom Commands section of the Tiltfile Concepts doc). For example

yaml = local('kustomize build Kustomization')
k8s_yaml(yaml)

>All comments

Hi @fentas thanks for the report! I'll fix this. In the meantime you can run kustomize by hand with a local (for more info see the Custom Commands section of the Tiltfile Concepts doc). For example

yaml = local('kustomize build Kustomization')
k8s_yaml(yaml)
Was this page helpful?
0 / 5 - 0 ratings