Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "CP-52245: Temp disable repo_gpgcheck when syncing from remote_pool repo" #6196

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 3 additions & 10 deletions ocaml/xapi/repository.ml
Original file line number Diff line number Diff line change
Expand Up @@ -155,27 +155,21 @@ let sync ~__context ~self ~token ~token_id ~username ~password =
remove_repo_conf_file repo_name ;
let origin = Db.Repository.get_origin ~__context ~self in

let ( binary_url
, source_url
, repo_gpgcheck
, use_proxy
, client_auth
, server_auth ) =
let binary_url, source_url, use_proxy, client_auth, server_auth =
match origin with
| `remote ->
let plugin = "accesstoken" in
( Db.Repository.get_binary_url ~__context ~self
, Some (Db.Repository.get_source_url ~__context ~self)
, true
, true
, CdnTokenAuth {token_id; token; plugin}
, DefaultAuth
)
| `bundle ->
let uri =
Uri.make ~scheme:"file" ~path:!Xapi_globs.bundle_repository_dir ()
in
(Uri.to_string uri, None, true, false, NoAuth, NoAuth)
(Uri.to_string uri, None, false, NoAuth, NoAuth)
| `remote_pool ->
let cert = Db.Repository.get_certificate ~__context ~self in
let repo_binary_url = Db.Repository.get_binary_url ~__context ~self in
Expand Down Expand Up @@ -215,7 +209,6 @@ let sync ~__context ~self ~token ~token_id ~username ~password =
let plugin = "xapitoken" in
( repo_binary_url
, None
, false
, true
, PoolExtHostAuth {xapi_token; plugin}
, StunnelClientProxyAuth
Expand All @@ -230,7 +223,7 @@ let sync ~__context ~self ~token ~token_id ~username ~password =
s
in
let write_initial_yum_config ~binary_url =
write_yum_config ~source_url ~binary_url ~repo_gpgcheck ~gpgkey_path
write_yum_config ~source_url ~binary_url ~repo_gpgcheck:true ~gpgkey_path
~repo_name
in
Xapi_stdext_pervasives.Pervasiveext.finally
Expand Down
Loading