diff --git a/dedal/build_cache/BuildCacheManager.py b/dedal/build_cache/BuildCacheManager.py index 63b8b455775c3bbfcb7e588af1e75040c568b611..dd20483a68e4cf1d67ffab4461dfe2a7e3f08cd3 100644 --- a/dedal/build_cache/BuildCacheManager.py +++ b/dedal/build_cache/BuildCacheManager.py @@ -15,8 +15,7 @@ class BuildCacheManager(BuildCacheManagerInterface): """ def __init__(self, registry_host, registry_project, registry_username, registry_password, cache_version='cache', - auth_backend='basic', - insecure=False): + auth_backend='basic', insecure=False, tls_verify=True): self._logger = get_logger(__name__, BuildCacheManager.__name__) self._registry_project = registry_project @@ -29,7 +28,7 @@ class BuildCacheManager(BuildCacheManagerInterface): # Refer to the official OCI Registry documentation for detailed information on the available authentication methods. # Supported authentication types may include basic authentication (username/password), token-based authentication, self._client = oras.client.OrasClient(hostname=self._registry_host, auth_backend=auth_backend, - insecure=insecure) + insecure=insecure, tls_verify=tls_verify) self._client.login(username=self._registry_username, password=self._registry_password) self.cache_version = cache_version self._oci_registry_path = f'{self._registry_host}/{self._registry_project}/{self.cache_version}' @@ -53,7 +52,7 @@ class BuildCacheManager(BuildCacheManagerInterface): tag = str(sub_path.name) rel_path = str(sub_path.relative_to(build_cache_path)).replace(tag, "") target = f"{self._registry_host}/{self._registry_project}/{self.cache_version}:{tag}" - upload_file = True + upload_file = True if update_cache is False and tag in tags: upload_file = False if upload_file: