Skip to content

Use UID for dockerfile to allow runAsNonRoot to be used.#95390

Merged
mark-vieira merged 1 commit intoelastic:mainfrom
naemono:dockerfile-use-uid-not-name
Apr 19, 2023
Merged

Use UID for dockerfile to allow runAsNonRoot to be used.#95390
mark-vieira merged 1 commit intoelastic:mainfrom
naemono:dockerfile-use-uid-not-name

Conversation

@naemono
Copy link
Contributor

@naemono naemono commented Apr 19, 2023

See elastic/cloud-on-k8s#6688 (comment)

This change will allow the Elasticsearch container in Kubernetes to be ran with runAsNonRoot as it checks against the numeric UID, and not a name.

Without this change you encounter the following error:

Warning  Failed     2m10s (x12 over 3m48s)  kubelet            Error: container has runAsNonRoot and image has non-numeric user (elasticsearch), cannot verify user is non-root

Signed-off-by: Michael Montgomery <mmontg1@gmail.com>
@elasticsearchmachine elasticsearchmachine added needs:triage Requires assignment of a team area label v8.8.0 external-contributor Pull request authored by a developer outside the Elasticsearch team labels Apr 19, 2023
@mark-vieira mark-vieira self-assigned this Apr 19, 2023
@mark-vieira mark-vieira added the :Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts label Apr 19, 2023
@elasticsearchmachine elasticsearchmachine added Team:Delivery Meta label for Delivery team and removed needs:triage Requires assignment of a team area label labels Apr 19, 2023
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-delivery (Team:Delivery)

Copy link
Contributor

@mark-vieira mark-vieira left a comment

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts >enhancement external-contributor Pull request authored by a developer outside the Elasticsearch team Team:Delivery Meta label for Delivery team v8.8.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants