Skip to content
This repository has been archived by the owner on May 16, 2023. It is now read-only.

[kibana] run as non root by default #164

Closed
naseemkullah opened this issue Jun 17, 2019 · 4 comments
Closed

[kibana] run as non root by default #164

naseemkullah opened this issue Jun 17, 2019 · 4 comments
Labels

Comments

@naseemkullah
Copy link
Contributor

Describe the feature:
Please see title.

Describe a specific use case for the feature:
Best practice, although podSecurityContext is configurable, running as non root should not have to be explicitly set. The reverse should be true (one should have to explicitly set they want to run as root).

@Crazybus
Copy link
Contributor

Leaving the same comment as for #163 that this seems to be related to some changes in Kubernetes 1.13. I'm adding support for 1.13 in #169. But still worth noting that Kibana does not seem to be running as the root user (at least in Kubernetes < 1.13).

sh-4.2$ ps aux 1
USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
kibana         1 71.8  1.2 1468548 392852 ?      Ssl  18:20   0:40 /usr/share/kibana/bin/../node/bin/node --no-warnings --max-http-header-size=65536 /usr/share/kibana/bin/../src/cli
sh-4.2$ id
uid=1000(kibana) gid=1000(kibana) groups=1000(kibana)
sh-4.2$ id kibana
uid=1000(kibana) gid=1000(kibana) groups=1000(kibana)

Could you confirm on one of these issues that you are seeing the same error as in #162 and not that your Kibana instance is somehow running as root?

@naseemkullah
Copy link
Contributor Author

Hi @Crazybus similarly, although the process is not being run by root but rather by the kibana user, the container itself is still running as root, so if it is compromised, the compromiser will be root in the container.
It would be better to add the appropriate securityContext to run as non root.

I will gladly make a PR

@Crazybus
Copy link
Contributor

The PR is here: #172

@jmlrt jmlrt added enhancement New feature or request feature and removed enhancement New feature or request labels Sep 23, 2019
@jmlrt
Copy link
Member

jmlrt commented Oct 3, 2019

Hi @naseemkullah,
I'm closing this issue as your PR #172 was merged.

@jmlrt jmlrt closed this as completed Oct 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants