docs: def hash_file(self, path, saltenv='base'):
          '''
          Return the hash of a file, to get the hash of a file in the pillar_roots
          prepend the path with salt://<file on server> otherwise, prepend the
          file with / for a local file.
          '''
          ret = {}
          fnd = self.__get_file_path(path, saltenv)
          if fnd is None:
              return ret
  
          try:
              # Remote file path (self._find_file() invoked)
              fnd_path = fnd['path']
          except TypeError:
              # Local file path
              fnd_path = fnd
  
          hash_type = self.opts.get('hash_type', 'md5')
          ret['hsum'] = salt.utils.hashutils.get_hash(fnd_path, form=hash_type)
          ret['hash_type'] = hash_type
          return ret