Skip to content

Commit 12d3b41

Browse files
authored
Update Dockerfile
add forked alpine py3 with symlink to /usr/bin/python
1 parent 93ddb24 commit 12d3b41

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

3.8/alpine3.12/Dockerfile

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
FROM alpine:3.12
88

99
# ensure local python is preferred over distribution python
10-
ENV PATH /usr/local/bin:$PATH
10+
ENV PATH /usr/local/bin:/usr/bin:$PATH
1111

1212
# http://bugs.python.org/issue19846
1313
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
@@ -134,4 +134,12 @@ RUN set -ex; \
134134
\) -exec rm -rf '{}' +; \
135135
rm -f get-pip.py
136136

137-
CMD ["python3"]
137+
# symlink to /usr/bin/python
138+
ENV PATH /usr/bin:$PATH
139+
RUN ln -s /usr/local/bin/python3 /usr/bin/python;
140+
RUN alias python=python3;
141+
RUN ls /usr/bin -al;
142+
RUN ls -al /usr/local/bin;
143+
RUN /usr/bin/python --version;
144+
145+
ENTRYPOINT ["/usr/bin/python"]

0 commit comments

Comments
 (0)