docs: def qemu_rebase(target, backing_file, safe=True, fail_on_error=True):
      """
      changes the backing file of 'source' to 'backing_file'
      If backing_file is specified as "" (the empty string),
      then the image is rebased onto no backing file
      (i.e. it will exist independently of any backing file).
      (Taken from qemu-img man page)
  
      Args:
          target(str): Path to the source disk
          backing_file(str): path to the base disk
          safe(bool): if false, allow unsafe rebase
           (check qemu-img docs for more info)
      """
      cmd = ['qemu-img', 'rebase', '-b', backing_file, target]
      if not safe:
          cmd.insert(2, '-u')
  
      return run_command_with_validation(
          cmd,
          fail_on_error,
          msg='Failed to rebase {target} onto {backing_file}'.format(
              target=target, backing_file=backing_file
          )
      )