Skip to content

Commit 6003dae

Browse files
authored
Merge pull request #278 from infosiftr/python2-io-encoding
Set PYTHONIOENCODING for Python 2
2 parents 016aedf + 2c06746 commit 6003dae

File tree

8 files changed

+16
-0
lines changed

8 files changed

+16
-0
lines changed

2.7/alpine3.4/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# install ca-certificates so that HTTPS works consistently
1113
# the other runtime dependencies for Python are installed later

2.7/alpine3.6/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# install ca-certificates so that HTTPS works consistently
1113
# the other runtime dependencies for Python are installed later

2.7/alpine3.7/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# install ca-certificates so that HTTPS works consistently
1113
# the other runtime dependencies for Python are installed later

2.7/jessie/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# runtime dependencies
1113
RUN apt-get update && apt-get install -y --no-install-recommends \

2.7/jessie/slim/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# runtime dependencies
1113
RUN apt-get update && apt-get install -y --no-install-recommends \

2.7/stretch/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# runtime dependencies
1113
RUN apt-get update && apt-get install -y --no-install-recommends \

2.7/stretch/slim/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# runtime dependencies
1113
RUN apt-get update && apt-get install -y --no-install-recommends \

2.7/wheezy/Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ ENV PATH /usr/local/bin:$PATH
66
# http://bugs.python.org/issue19846
77
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
88
ENV LANG C.UTF-8
9+
# https://github.com/docker-library/python/issues/147
10+
ENV PYTHONIOENCODING UTF-8
911

1012
# runtime dependencies
1113
RUN apt-get update && apt-get install -y --no-install-recommends \

0 commit comments

Comments
 (0)