File tree Expand file tree Collapse file tree 10 files changed +17
-10
lines changed Expand file tree Collapse file tree 10 files changed +17
-10
lines changed Original file line number Diff line number Diff line change @@ -47,3 +47,7 @@ rm -rf /etc/security/limits.d/20-nproc.conf
47
47
# Clean
48
48
yum clean all
49
49
rm -rf /anaconda-post.log /var/log/anaconda/*
50
+
51
+ # symlink for python3
52
+ ln -s /bin/python3 /bin/python
53
+ ln -sf /usr/bin/pip3.7 /usr/bin/pip3
Original file line number Diff line number Diff line change 49
49
50
50
# symlink for python3
51
51
ln -s /bin/python3 /bin/python
52
+ ln -sf /usr/bin/pip3.7 /usr/bin/pip3
52
53
53
54
# Clean
54
55
yum clean all
Original file line number Diff line number Diff line change @@ -92,3 +92,7 @@ chmod u+s /bin/ping
92
92
# Clean
93
93
apt clean autoclean
94
94
rm -rf /var/lib/apt/lists/*
95
+
96
+ # Symlink python/pip
97
+ ln -sf /usr/bin/python3.7 /usr/bin/python3
98
+ ln -sf /usr/bin/pip3.7 /usr/bin/pip3
Original file line number Diff line number Diff line change @@ -93,3 +93,7 @@ chmod u+s /bin/ping
93
93
# Clean
94
94
apt clean autoclean
95
95
rm -rf /var/lib/apt/lists/*
96
+
97
+ # Symlink python/pip
98
+ ln -sf /usr/bin/python3.7 /usr/bin/python3
99
+ ln -sf /usr/bin/pip3.7 /usr/bin/pip3
Original file line number Diff line number Diff line change @@ -17,8 +17,7 @@ RUN wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz \
17
17
&& python3.7 get-pip.py \
18
18
&& rm -f get-pip.py \
19
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
20
+ && ln -sf /usr/bin/pip2 /usr/bin/pip
22
21
RUN yum remove -y --setopt=tsflags=noscripts gcc openssl-devel bzip2-devel libffi-devel \
23
22
&& yum autoremove -y \
24
23
&& yum clean all
Original file line number Diff line number Diff line change @@ -18,8 +18,7 @@ RUN wget https://www.python.org/ftp/python/3.7.4/Python-3.7.4.tgz \
18
18
&& python3.7 get-pip.py \
19
19
&& rm -f get-pip.py \
20
20
# pip version is not automatically "fixed", unlike debian-based
21
- && ln -sf /usr/bin/pip2 /usr/bin/pip \
22
- && ln -sf /usr/bin/pip3.7 /usr/bin/pip3
21
+ && ln -sf /usr/bin/pip2 /usr/bin/pip
23
22
# add python alias
24
23
# && ln -s /bin/python3 /bin/python
25
24
Original file line number Diff line number Diff line change @@ -4,8 +4,6 @@ USER root
4
4
5
5
RUN apt-get update -y \
6
6
&& apt-get install -y --no-install-recommends libpython-dev python-pip python-requests python-jmespath python-yaml \
7
- && ln -sf /usr/bin/python3.7 /usr/bin/python3 \
8
- && ln -sf /usr/bin/pip3.7 /usr/bin/pip3 \
9
7
&& ln -sf /usr/bin/python3.7 /usr/bin/python \
10
8
&& ln -sf /usr/bin/pip3.7 /usr/bin/pip \
11
9
&& pip3 install --upgrade ansible==3.4.0 requests==2.25.1 pyyaml==5.4.1 jmespath==0.10.0
Original file line number Diff line number Diff line change @@ -4,8 +4,6 @@ USER root
4
4
5
5
RUN apt-get update -y \
6
6
&& apt-get install -y --no-install-recommends libpython-dev python-pip python-requests python-jmespath python-yaml \
7
- && ln -sf /usr/bin/python3.7 /usr/bin/python3 \
8
- && ln -sf /usr/bin/pip3.7 /usr/bin/pip3 \
9
7
&& ln -sf /usr/bin/python3.7 /usr/bin/python \
10
8
&& ln -sf /usr/bin/pip3.7 /usr/bin/pip \
11
9
&& pip3 install --upgrade ansible==3.4.0 requests==2.25.1 pyyaml==5.4.1 jmespath==0.10.0
Original file line number Diff line number Diff line change @@ -8,5 +8,4 @@ RUN microdnf -y --nodocs update \
8
8
&& pip2 --no-cache-dir install requests pyyaml jmespath \
9
9
&& ln -sf /usr/bin/python3.9 /usr/bin/python \
10
10
&& ln -sf /usr/bin/pip3.9 /usr/bin/pip \
11
- && pip3 install --upgrade requests==2.25.1 pyyaml==5.4.1 jmespath==0.10.0 \
12
- && sed -i '/^\[ defaults\] /a\i nterpreter_python = /usr/bin/python3' /opt/ansible/ansible.cfg
11
+ && pip3 install --upgrade requests==2.25.1 pyyaml==5.4.1 jmespath==0.10.0
Original file line number Diff line number Diff line change @@ -112,6 +112,7 @@ RUN sed -i -e 's/%sudo\s\+ALL=(ALL\(:ALL\)\?)\s\+ALL/%sudo ALL=NOPASSWD:ALL\nans
112
112
&& chgrp ${ANSIBLE_GROUP} ${SPLUNK_ANSIBLE_HOME} ${SPLUNK_ANSIBLE_HOME}/ansible.cfg \
113
113
&& chmod 775 ${SPLUNK_ANSIBLE_HOME} \
114
114
&& chmod 664 ${SPLUNK_ANSIBLE_HOME}/ansible.cfg \
115
+ && sed -i '/^\[ defaults\] /a\i nterpreter_python = /usr/bin/python3' ${SPLUNK_ANSIBLE_HOME}/ansible.cfg \
115
116
&& chmod 755 /sbin/entrypoint.sh /sbin/createdefaults.py /sbin/checkstate.sh
116
117
117
118
USER ${ANSIBLE_USER}
You can’t perform that action at this time.
0 commit comments