Skip to content

Commit

Permalink
CP-52245: Temp disable repo_gpgcheck when syncing from remote_pool repo
Browse files Browse the repository at this point in the history
Will re-enable repo_gpgcheck by reverting this commit after CP-51429 is done.

Signed-off-by: Gang Ji <[email protected]>
  • Loading branch information
gangj committed Dec 12, 2024
1 parent ca97d0f commit 61c948b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions ocaml/xapi/repository.ml
Original file line number Diff line number Diff line change
Expand Up @@ -175,20 +175,22 @@ 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
)
| `bundle ->
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
Expand All @@ -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
{
Expand All @@ -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 () ;
Expand Down

0 comments on commit 61c948b

Please sign in to comment.