1

I know that I can use Kustomize's configMapGenerator to create a configmap from a file that resides in the same Git repository as the "kustomization.yaml" file.

For Example:

apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
  - deployment.yaml
configMapGenerator:
- name: my-config
  files:
  - config-file.json

But is it possible to create a configMap from a file that resides in a different Git repository?

For example:

apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
resources:
  - deployment.yaml
configMapGenerator:
- name: my-config
  files:
  - git::ssh://git@bitbucket.company.com:7999/proj/repo-name.git//config-file.json
  • Kustomize is not able to fetch individual files from a remote repository, but it can treat a remote repository as a `resource` if it contains a `kustomization.yaml` file. – larsks Jul 11 '23 at 20:26

0 Answers0