-
Notifications
You must be signed in to change notification settings - Fork 580
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
Allow scanning sub dir within a larger search context #3213
Comments
We talked about a few different implementation options here, both from a user-facing level and lower API level.
1 & 2 are relatively simple to add to syft but are not "automagical" in the sense that the user might need to know a lot about our catalogers today to put in just the right amount of paths to include. 3 introduces a new problem: how would catalogers add paths that are semantically useful but don't accidentally add paths that produce packages that otherwise would not have been found. That is, if the user is interested in 4 is relatively difficult to implement, but overcomes most of the problems of 3. Take for example, the dpkg cataloger finds packages, but when searching for md5sum files in the the parent dir this comes back with no locations. At this point we could smuggle an index builder/requester through file.Resolver that could be invoked by the cataloger to add the info dir to the resolver. This would be something of the affect of There are several other considerations with 4 that are important:
|
What would you like to be added:
We have multiple issues that want to be able to search within a small space, but reference things outside of that space:
It would be nice to allow for something like this:
Were I only want to catalog packages within
./my/dir/project-1
but I want to be able to reference file system material from a specific parent directory./my/dir
In this way if there is a pom.xml in the project dir but the parent pom has required properties, we can reference that material to get the correct version. This applies to any ecosystem where manifests can reference other manifests in parent directories for correct resolution.
Today we have the
--exclude
flag to tailor the search space, but this doesn't help in a large set of cases (and may result in cumbersome number of flags or brittle configuration).The text was updated successfully, but these errors were encountered: