File tree Expand file tree Collapse file tree 2 files changed +14
-3
lines changed Expand file tree Collapse file tree 2 files changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -20,6 +20,6 @@ RUN wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz \
2020 && ln -sf /usr/bin/pip2 /usr/bin/pip \
2121 && ln -sf /usr/bin/pip3.7 /usr/bin/pip3
2222RUN yum remove -y --setopt=tsflags=noscripts gcc openssl-devel bzip2-devel libffi-devel \
23- && yum -y autoremove \
23+ && yum autoremove -y \
2424 && yum clean all
2525RUN pip3 --no-cache-dir install ansible requests
Original file line number Diff line number Diff line change @@ -2,13 +2,24 @@ ARG SPLUNK_PRODUCT=splunk
22FROM ${SPLUNK_PRODUCT}-redhat-8:latest
33USER root
44
5+ RUN microdnf -y update \
6+ && microdnf -y install make gcc openssl-devel bzip2-devel libffi-devel
57# INFRA-15385: manual installation of python 3.7 as default distro version is 3.6
68RUN wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz \
79 && tar xzf Python-3.7.4.tgz \
810 && cd Python-3.7.4 \
911 && ./configure --enable-optimizations --prefix=/usr \
10- && make altinstall \
12+ && make install \
1113 && cd .. \
1214 && rm Python-3.7.4.tgz \
13- && rm -r Python-3.7.4
15+ && rm -r Python-3.7.4 \
16+ && curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py \
17+ && python3.7 get-pip.py \
18+ && rm -f get-pip.py \
19+ # pip version is not automatically "fixed", unlike debian-based
20+ && ln -sf /usr/bin/pip2 /usr/bin/pip \
21+ && ln -sf /usr/bin/pip3.7 /usr/bin/pip3
22+ # microdnf persists metadata which is a problem for removing packages. So have to clean first before removing.
23+ RUN microdnf clean all \
24+ && microdnf remove -y gcc make openssl-devel bzip2-devel libffi-devel
1425RUN pip3 -q --no-cache-dir install requests ansible
You can’t perform that action at this time.
0 commit comments