Skip to content

Fix elasticsearch docs: ID=1 sudo ... is ineffective

What does this MR do?

Fix some documentation so that the examples work as expected. Setting environment variables before running sudo is ineffective, as sudo starts with a clean environment (unless sudo -E is used). Rake allows the variables to be specified on the command line, so do that instead.

Are there points in the code the reviewer needs to double check?

We could have used sudo -E instead, but this seems safer to me.

Why was this MR needed?

Broken documentation discovered during https://gitlab.com/gitlab-com/infrastructure/issues/1477#note_26878192

Does this MR meet the acceptance criteria?

Merge request reports