I understand Filebeat’s Docker image switched in version 9.0.0 from an Ubuntu base to redhat/ubi9-minimal
The tree command thus no longer works inside the docker image, how can I install it? It doesn’t work with microdnf. To use EPEL do I need a redhat subscription?
I found some related docs from redhat (which this forum won’t allow me to link to ) but tree doesn’t seem to be available in the default package repos.
$ microdnf repolist
(microdnf:529): librhsm-WARNING **: 10:58:43.795: Found 0 entitlement certificates
(microdnf:529): librhsm-WARNING **: 10:58:43.796: Found 0 entitlement certificates
repo id repo name
ubi-9-appstream-rpms Red Hat Universal Base Image 9 (RPMs) - AppStream
ubi-9-baseos-rpms Red Hat Universal Base Image 9 (RPMs) - BaseOS
ubi-9-codeready-builder-rpms Red Hat Universal Base Image 9 (RPMs) - CodeReady Builder
# no results:
$ rpm -qa | grep -i tree
I also enabled EPEL but it doesn’t appear to contain tree either
Hi @leandrojmp thanks for the advice, yum doesn’t appear to be available in the docker image though I think it’s just microdnf and the rpm command.
Here’s my Dockerfile for reference:
FROM elastic/filebeat:9.1.2 AS base
USER root
RUN microdnf install -y which
when I get a shell into the container after building I observe there’s no yum, yum: command not found.
maybe this is a similar command to the one you’re suggesting:
$ microdnf repoquery | grep -i tree
(microdnf:116): librhsm-WARNING **: 15:44:34.089: Found 0 entitlement certificates
(microdnf:116): librhsm-WARNING **: 15:44:34.091: Found 0 entitlement certificates
ostree-2025.1-1.el9.i686
ostree-2025.1-1.el9.x86_64
ostree-libs-2025.1-1.el9.i686
ostree-libs-2025.1-1.el9.x86_64
I tried microdnf install -y ostree-2025.1-1.el9.x86_64 ostree-libs-2025.1-1.el9.x86_64 just to be sure but these don’t provide the tree command.
Is it possible that such a command like tree is only available in the full version of red hat (requiring a license). Cause I don’t see it in EPEL either
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.