[Libguestfs] [PATCH 0/5] [RFC] builder: handle unavailable repos

Pino Toscano
Wed, 16 Jan 2019 14:17:30 -0000

In case a repository of virt-builder references files (e.g. the index)
that cannot be downloaded (network issues, 404, etc) then virt-builder
errors out on this situation. This is not a nice situation, from an user
POV.

This series does some refactoring to allow to better handle downloading
failures, and handle the failures gracefully in virt-builder.

RFC because I'm not yet too convinced the approach I used (especially
for the changes in the Curl module) is optimal, so looking for feedback
on this.

Pino Toscano (5):
  mltools: split helper do_check_exitcode
  mltools: create a new external_command_code
  mltools: add simple tests for external_command
  mltools: curl: turn Curl.run to raise exceptions
  builder: ignore repositories with download failures

 builder/builder.ml                  | 39 ++++++++++++++++++++---------
 common/mltools/curl.ml              | 15 ++++++++++-
 common/mltools/curl.mli             |  3 +++
 common/mltools/tools_utils.ml       | 26 +++++++++----------
 common/mltools/tools_utils.mli      |  8 ++++++
 common/mltools/tools_utils_tests.ml | 22 ++++++++++++++++
 v2v/copy_to_local.ml                |  9 ++++++-
 v2v/v2v.ml                          |  9 ++++++-
 8 files changed, 103 insertions(+), 28 deletions(-)

--
2.20.1