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

Clarify use for shared_credential_file #20929

Merged
merged 1 commit into from
Sep 3, 2020

Conversation

kostasb
Copy link
Contributor

@kostasb kostasb commented Sep 2, 2020

When starting Beats as a service, the Beat's PID will be owned by the user that manages the service. This would be root in most cases.

Users tend to run tests as non-root, running beats directly (./metricbeat) on the command line. Without the shared_credential_file path the beat checks for credentials under the user's home directory.

As a service, the home directory of the user managing the service (typically root) tends to be different than that of the user in testing and development, which can be difficult to figure out.

What does this PR do?

Clarifies AWS module's credential lookup behavior and when to use shared_credential_file to avoid ambiguity.

Why is it important?

Helps users avoid credential lookup issues, especially deviations between environments where Beats run as standalone process vs service.

When starting beats as a service, the PID will be owned by the user that manages the service. This would be root in most cases. Users tend to run tests as non-root, running beats directly (./metricbeat) on the command line. Without the shared_credential_file path the beat checks for credentials under the user's home directory. When starting beats as a service, the home directory of the user managing the service (typically root) is different than what was being used in testing and development, which can be hard to figure out.
@kostasb kostasb added docs Team:Docs Label for the Observability docs team labels Sep 2, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/obs-docs (Team:Docs)

@botelastic botelastic bot added needs_team Indicates that the issue/PR needs a Team:* label and removed needs_team Indicates that the issue/PR needs a Team:* label labels Sep 2, 2020
@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

Pipeline View Test View Changes Artifacts preview

Expand to view the summary

Build stats

  • Build Cause: [Pull request #20929 opened]

  • Start Time: 2020-09-02T14:36:26.670+0000

  • Duration: 28 min 40 sec

@kostasb kostasb merged commit cbed0d6 into master Sep 3, 2020
@kostasb kostasb deleted the kostasb-metricbeat-shared_credential_file branch September 3, 2020 14:01
v1v added a commit to v1v/beats that referenced this pull request Sep 3, 2020
…ne-2.0

* upstream/master:
  Release Kubernetes state metricsets as GA (elastic#20901)
  Clarify use for shared_credential_file (elastic#20929)
@kaiyan-sheng kaiyan-sheng self-assigned this Sep 14, 2020
@kaiyan-sheng
Copy link
Contributor

@kostasb Thank you for adding this! I will backport this PR to 7.x and other branches 😄

kaiyan-sheng added a commit that referenced this pull request Sep 15, 2020
(cherry picked from commit cbed0d6)

Co-authored-by: Kostas Botsas <kostas.botsas@elastic.co>
kaiyan-sheng added a commit that referenced this pull request Sep 15, 2020
(cherry picked from commit cbed0d6)

Co-authored-by: Kostas Botsas <kostas.botsas@elastic.co>
kaiyan-sheng added a commit that referenced this pull request Sep 15, 2020
(cherry picked from commit cbed0d6)

Co-authored-by: Kostas Botsas <kostas.botsas@elastic.co>
melchiormoulin pushed a commit to melchiormoulin/beats that referenced this pull request Oct 14, 2020
When starting beats as a service, the PID will be owned by the user that manages the service. This would be root in most cases. Users tend to run tests as non-root, running beats directly (./metricbeat) on the command line. Without the shared_credential_file path the beat checks for credentials under the user's home directory. When starting beats as a service, the home directory of the user managing the service (typically root) is different than what was being used in testing and development, which can be hard to figure out.
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
(cherry picked from commit f2c9616)

Co-authored-by: Kostas Botsas <kostas.botsas@elastic.co>
leweafan pushed a commit to leweafan/beats that referenced this pull request Apr 28, 2023
(cherry picked from commit f2c9616)

Co-authored-by: Kostas Botsas <kostas.botsas@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Team:Docs Label for the Observability docs team v7.8.2 v7.9.2 v7.10.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants