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

Download compressed gz image from remote source #41

Merged
merged 5 commits into from
Dec 16, 2022
Merged

Commits on Dec 14, 2022

  1. bmap::copy_async to asynchronous copy disk image

    Prepare bmap copy from remote source. Create an asynchronous alternative pipeline
    for asynchronous copy data downloaded from remote source. We want the data to be
    streamed into the copying function instead of be fully downloaded before the copy
    start, shortening the duration of the overall process.
    
    Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
    Razaloc committed Dec 14, 2022
    Configuration menu
    Copy the full SHA
    e21fd28 View commit details
    Browse the repository at this point in the history
  2. Custom parser to allow Url input

    Change the use of clap from 'derive' to 'builder' mode. The goal is to allow
    Copy.image to be an enum holding a PathBuf or an Url, allowing Url inputs for
    the copy function. This way, we only parse the input value once.
    
    Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
    Razaloc committed Dec 14, 2022
    Configuration menu
    Copy the full SHA
    e0a577a View commit details
    Browse the repository at this point in the history
  3. Avoid duplicating code

    The current copy function and the future copy_remote_input function will share
    a lot of code. We are trying to reduce that duplication, extracting parts and
    creating setup_progress_bar and setup_output.
    
    Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
    Razaloc committed Dec 14, 2022
    Configuration menu
    Copy the full SHA
    3ffac65 View commit details
    Browse the repository at this point in the history
  4. Download compressed gz image from remote source

    Accept Url arguments for remote image download and copy. Implements async support
    for use of reqwest. Bmap file is searched as in local option in the current file
    with same name and the extension ".bmap"
    
    Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
    Razaloc committed Dec 14, 2022
    Configuration menu
    Copy the full SHA
    daeced4 View commit details
    Browse the repository at this point in the history
  5. Download bmap from remote source

    When downloading the image from a remote source, the bmap will also be searched
    remotely and downloaded. The bmap url will be the same as image url, but replacing
    the final extension with ".bmap".
    
    Signed-off-by: Rafael Garcia Ruiz <rafael.garcia@collabora.com>
    Razaloc committed Dec 14, 2022
    Configuration menu
    Copy the full SHA
    5a6e346 View commit details
    Browse the repository at this point in the history