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

[s3-repository] Don't fail if there no symlink for AWS Web Identity Token #84697

Conversation

arteam
Copy link
Contributor

@arteam arteam commented Mar 7, 2022

Make sure users can use the static credentials even if there is a service account with IAM roles configured on the system.

See #52625 (comment)

Make sure users can use the static credentials even if there is a service account with IAM roles
configured on the system.
@arteam arteam added >bug :Distributed/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs auto-backport Automatically create backport pull requests when merged v8.2.0 v8.1.1 v8.0.2 labels Mar 7, 2022
@elasticmachine elasticmachine added the Team:Distributed Meta label for distributed team label Mar 7, 2022
@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-distributed (Team:Distributed)

@elasticsearchmachine
Copy link
Collaborator

Hi @arteam, I've created a changelog YAML for you.

@arteam arteam changed the title Don't fail if there no symlink for AWS Web Identity Token [s3-repository] Don't fail if there no symlink for AWS Web Identity Token Mar 7, 2022
@arteam arteam requested a review from tlrx March 7, 2022 10:47
}
if (Files.isReadable(webIdentityTokenFileSymlink) == false) {
throw new IllegalStateException("Unable to read a Web Identity Token symlink in the config directory");
LOGGER.warn("Unable to read a Web Identity Token symlink in the config directory");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At this stage the user has configured the env var and created a symlink that should point to it, but we can't read it. To me we should fail here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are reports from users who have this environment variable configured, but they do not want to use it (and configure a symlink) and prefer to use static credentials (#52625 (comment)).

@arteam arteam requested a review from tlrx March 7, 2022 14:16
Copy link
Member

@tlrx tlrx left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but I left comments to address

@arteam arteam merged commit d965595 into elastic:master Mar 9, 2022
@arteam arteam deleted the do-not-fail-if-there-no-aws-web-identity-token-symlink branch March 9, 2022 16:09
@arteam
Copy link
Contributor Author

arteam commented Mar 9, 2022

Thanks Tanguy!

arteam added a commit to arteam/elasticsearch that referenced this pull request Mar 9, 2022
…oken (elastic#84697)

Make sure users can use the static credentials even if there is a service account with IAM roles configured on the system.

See elastic#52625 (comment)

(cherry picked from commit d965595)
arteam added a commit to arteam/elasticsearch that referenced this pull request Mar 9, 2022
…oken (elastic#84697)

Make sure users can use the static credentials even if there is a service account with IAM roles configured on the system.

See elastic#52625 (comment)

(cherry picked from commit d965595)
arteam added a commit that referenced this pull request Mar 9, 2022
…oken (#84697) (#84824)

Make sure users can use the static credentials even if there is a service account with IAM roles configured on the system.

See #52625 (comment)

(cherry picked from commit d965595)
arteam added a commit that referenced this pull request Mar 9, 2022
…oken (#84697) (#84825)

Make sure users can use the static credentials even if there is a service account with IAM roles configured on the system.

See #52625 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Automatically create backport pull requests when merged >bug :Distributed/Snapshot/Restore Anything directly related to the `_snapshot/*` APIs Team:Distributed Meta label for distributed team v8.0.2 v8.1.1 v8.2.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants