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

support generating separate blob for prefetched files #1629

Merged
merged 1 commit into from
Oct 29, 2024

Commits on Oct 29, 2024

  1. builder: introduce optimize subcommand for prefetch

    We can statically analyze the image entrypoint dependency, or use runtime dynamic
    analysis technologies such as ebpf, fanotify, metric, etc. to obtain the container
    file access pattern, and then build this part of data into an independent image layer:
    
    * preferentially fetch blob during the image startup phase to reduce network and disk IO.
    * avoid frequent image builds, allows for better local cache utilization.
    
    Implement optimize subcommand to optimize image bootstrap
    from a prefetch file list, generate a new blob.
    
    ```
    nydus-image optimize --prefetch-files /path/to/prefetch-files.txt \
      --bootstrap /path/to/bootstrap \
      --blob-dir /path/to/blobs
    ```
    This will generate a new bootstrap and new blob in `blob-dir`.
    
    Signed-off-by: daiyongxuan <[email protected]>
    daiyongxuan committed Oct 29, 2024
    Configuration menu
    Copy the full SHA
    1b4a4db View commit details
    Browse the repository at this point in the history