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

Trying to use a credentials file with AWS auth throws an error #16632

Closed
protochron opened this issue Feb 28, 2023 · 1 comment · Fixed by #16633
Closed

Trying to use a credentials file with AWS auth throws an error #16632

protochron opened this issue Feb 28, 2023 · 1 comment · Fixed by #16633
Labels
type: bug A code related bug.

Comments

@protochron
Copy link
Contributor

protochron commented Feb 28, 2023

A note for the community

I have a PR ready to go to fix this.

Problem

The Vector docs indicate that AWS credential files are supported as an authentication method, however that doesn't seem to be the case. Attempting to use a credentials file in a sink ends up with a log message indicating an error (Overriding the credentials file is not supported.). Reading the code, it looks like the credentials provider implementation does not actually support this method.

Since this method of AWS authentication is intended to be supported, it should actually work.

Configuration

[api]
enabled = true
address = "127.0.0.1:8686"

[sources.internal_metrics]
type = "internal_metrics"
scrape_interval_secs = 15

[sinks.prometheus_remote_write]
type     = "prometheus_remote_write"
inputs   = ["internal_metrics"]

auth.strategy = "aws"
auth.credentials_file = "secrets/aws.creds"
auth.profile = "default"
endpoint = "http://an-endpoint.example/api/v1/remote_write"
aws.region = "us-east-2"

Version

0.28.0

Debug Output

No response

Example Data

No response

Additional Context

No response

References

No response

@protochron protochron added the type: bug A code related bug. label Feb 28, 2023
protochron added a commit to protochron/vector that referenced this issue Mar 1, 2023
It looks like when Vector converted from rusoto to the official AWS SDK
that support for AWS credentials files was dropped. The docs indicate
this is supposed to be a supported option, so this PR adds support for
AWS credentials files by adding the correct credential provider.

Closes vectordotdev#16632.
@protochron
Copy link
Contributor Author

Updated the issue with a minimal example that shows how to reproduce the error. If you run that example through vector validate it shows the issue pretty clearly:

$ vector validate /tmp/vector.toml
√ Loaded ["/tmp/vector.toml"]

Component errors
----------------
x Sink "prometheus_remote_write": Overriding the credentials file is not supported.```

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A code related bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant