From 642e1ac53e5ffe3ffbdb7779a65bb2e002fc6f57 Mon Sep 17 00:00:00 2001 From: Gang Ji Date: Wed, 11 Dec 2024 01:07:52 +0800 Subject: [PATCH] CP-52245: Temp disable repo_gpgcheck when syncing from remote_pool repo Will re-enable repo_gpgcheck by reverting this commit after CP-51429 is done. Signed-off-by: Gang Ji --- ocaml/xapi/repository.ml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ocaml/xapi/repository.ml b/ocaml/xapi/repository.ml index 8e76ef4304..0cbb194d39 100644 --- a/ocaml/xapi/repository.ml +++ b/ocaml/xapi/repository.ml @@ -175,12 +175,14 @@ let sync ~__context ~self ~token ~token_id ~username ~password = let ( binary_url , source_url + , repo_gpgcheck , client_auth_config , client_proxy_config ) = match origin with | `remote -> ( Db.Repository.get_binary_url ~__context ~self , Some (Db.Repository.get_source_url ~__context ~self) + , true , Some (CdnTokenAuthConf {token; token_id}) , None ) @@ -188,7 +190,7 @@ let sync ~__context ~self ~token ~token_id ~username ~password = let uri = Uri.make ~scheme:"file" ~path:!Xapi_globs.bundle_repository_dir () in - (Uri.to_string uri, None, None, None) + (Uri.to_string uri, None, true, None, None) | `remote_pool -> let uri = Uri.make ~scheme:"http" ~host:local_host @@ -203,6 +205,7 @@ let sync ~__context ~self ~token ~token_id ~username ~password = let local_port = !Xapi_globs.local_yum_repo_port in ( Uri.to_string uri , None + , false , Some (PoolExtHostAuthConf {cert; remote_addr; username; password}) , Some { @@ -222,7 +225,7 @@ let sync ~__context ~self ~token ~token_id ~username ~password = s in let write_initial_yum_config () = - write_yum_config ~source_url ~binary_url ~repo_gpgcheck:true ~gpgkey_path + write_yum_config ~source_url ~binary_url ~repo_gpgcheck ~gpgkey_path ~repo_name in write_initial_yum_config () ;