skaffold
skaffold copied to clipboard
Skaffold configs are duplicated when you use a config dependency via git
But if you use a local dependency (via path
) it works fine
More context can be found in the discussion in kubernetes slack https://kubernetes.slack.com/archives/CABQMSZA6/p1645463031027819
Expected behavior
I expect when ServiceA depends on ServiceB, and ServiceB depends on ServiceA via git and I run skaffold in either of those services they both came up online without issues
Actual behavior
Because the config gets duplicated we effectively have three skaffold.yamls included in the finished "bundle", because of that skaffold fails
Information
- Skaffold version: v1.35.2
- Operating system: Darwin MacBook-Pro-Vladimir.local 20.3.0 Darwin Kernel Version 20.3.0: Thu Jan 21 00:07:06 PST 2021; root:xnu-7195.81.3~1/RELEASE_X86_64 x86_64
- Installed via: Homebrew
- Contents of skaffold.yaml:
https://github.com/vladimir-avinkin/skaffold-bug-serviceA https://github.com/vladimir-avinkin/skaffold-bug-serviceB
Steps to reproduce the behavior
- Clone both repos into the same directory
- Run
skaffold dev
in the skaffold-bug-serviceA directory - See an error similar to
invalid skaffold config: duplicate image "nginx" found in sources
- If you run
skaffold diagnose --yaml-only
you can see that we have 3 skaffold configs instead of two, and the config for the service where we have run skaffold is duplicated via git - Note if you switch a branch to
path
in both repositories and runskaffold dev
it works just fine
thanks for opening this issue @vladimir-avinkin
CC @gsquared94 , we can move discussion on this issue to this thread