Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error if --cache and --fetch is enabled #869

Open
MatteoVoges opened this issue Oct 21, 2022 · 1 comment
Open

Error if --cache and --fetch is enabled #869

MatteoVoges opened this issue Oct 21, 2022 · 1 comment

Comments

@MatteoVoges
Copy link
Contributor

MatteoVoges commented Oct 21, 2022

Describe the bug/feature
Kapitan should raise an error if the user uses flags --cache and --force-fetch (--fetch --force) together in one command.

To Reproduce
Steps to reproduce the behavior:
run $ kapitan compile --cache --fetch --force

Error:

$ kapitan compile --fetch --force --cache
Dependency helm chart filebeat and version 7.17.3: fetching now
Dependency helm chart filebeat and version 7.17.3: Error: failed to untar: a file or directory with the name .dependency_cache/a7918653/filebeat-7.17.3.tgz already exists

Error: failed to untar: a file or directory with the name .dependency_cache/a7918653/filebeat-7.17.3.tgz already exists

I don't know where the error comes from but it could be a problem for many targets with dependencies.

Furthermore with upcoming change #862 where you can specify the fetch_always tag in your dependencies we have to decide how kapitan should handle this situation.

Scenario:
You have one target, which has its fetch_always-tag set to true and one target where you want to get the dependencies from cache.
Currently Kapitan would throw an uncaught error.
The options to resolve that would be:

  • exclude all targets with fetch_always-tag from caching-process
  • add a get_from_cache-tag in the dependencies to allow the user to choose
  • don't allow different fetch/cache behavior for targets
@github-actions
Copy link

github-actions bot commented Oct 3, 2023

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale label Oct 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant