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

speed up structure test #54

Merged
merged 1 commit into from
Jul 6, 2023
Merged

Conversation

imjasonh
Copy link
Member

@imjasonh imjasonh commented Jul 6, 2023

  • Skip mutate.Extract if there's only one layer (for our images, there will only be one layer). mutate.Extract is wasteful and blocks if there's only one layer. I've tested this works with a multi-layer image as well.
  • Stop reading the tar stream if all the file checks we plan to run have run.

Signed-off-by: Jason Hall <jason@chainguard.dev>
@imjasonh imjasonh merged commit 7032e62 into chainguard-dev:main Jul 6, 2023
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants