Skip to content

Commit

Permalink
Ensure building works.
Browse files Browse the repository at this point in the history
  • Loading branch information
kihehs committed Sep 26, 2023
1 parent ba6e05f commit ecd77cb
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions src/registry/artifactory.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,20 @@ impl Artifactory {
reqwest::Client::builder().redirect(reqwest::redirect::Policy::none());

if let Some(token) = credentials.registry_tokens.get(&registry) {
tracing::info!(
uri=?registry.as_str(),
token_length=?token.len(),
"The {} header is set",
Self::JFROG_AUTH_HEADER,
);
if std::env::var("BUFFRS_TESTSUITE").is_err() {
tracing::info!(
uri=?registry.as_str(),
token_length=?token.len(),
"The {} header is set",
Self::JFROG_AUTH_HEADER,
);
}

let mut headers = HeaderMap::new();
headers.insert(Self::JFROG_AUTH_HEADER, token.parse()?);

client_builder = client_builder.default_headers(headers);
} else {
} else if std::env::var("BUFFRS_TESTSUITE").is_err() {
tracing::info!(
uri=?registry.as_str(),
"The {} header is NOT set",
Expand Down

0 comments on commit ecd77cb

Please sign in to comment.