kurtosis icon indicating copy to clipboard operation
kurtosis copied to clipboard

Respect .gitignore when uploading build context

Open lostbean opened this issue 11 months ago • 2 comments

Background & motivation

When using one of the features that builds images (e.g. ImageBuildSpec or NixBuildSpec) fails right now if you have large volume of data in the repo even if they are ignore data like local building and data caches.

Desired behaviour

I would to have the option (bonus if that is the default) to use gitignore to filter out what is upload to the Kurtosis building engine.

How important is this to you?

Painful; the lack of this feature makes using Kurtosis frictionful.

What area of the product does this pertain to?

CLI: the Command Line Interface

lostbean avatar Mar 06 '24 19:03 lostbean

Hey @lostbean , agree that we need a way to filter out this data! I'm not sure .gitignore is the right way to do this though, as Git is a separate system from Nix and Docker. E.g. Docker has its own .dockerignore, separate from .gitignore and I'd guess Nix has its own. Can we use those instead?

mieubrisse avatar Mar 06 '24 19:03 mieubrisse

Fair point, docker building could rely on things excluded by .gitignore. Nix doesn't have any special ignore system, most of the time it uses .gitignore for it. So a possible solution would be to ImageBuildSpec filter out based on . dockerignore and NixBuildSpec filter out based on . gitignore.

lostbean avatar Mar 06 '24 20:03 lostbean