Skip to content

Commit

Permalink
Add error code logging for bad credental requests
Browse files Browse the repository at this point in the history
  • Loading branch information
zhihonl committed Dec 12, 2024
1 parent 25a12e1 commit 225e184
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/aws/flb_aws_credentials_http.c
Original file line number Diff line number Diff line change
Expand Up @@ -463,6 +463,10 @@ static int http_credentials_request(struct flb_aws_provider_http
if (!c || c->resp.status != 200) {
flb_debug("[aws_credentials] http credentials request failed");
if (c) {
if (c->resp.payload_size > 0) {
flb_aws_print_error_code(c->resp.payload, c->resp.payload_size,
"ContainerCredentialsLocalServer");
}
flb_http_client_destroy(c);
}
if (auth_token) {
Expand Down

0 comments on commit 225e184

Please sign in to comment.