From ad923ad5642b2b11357fbee4277f3435300a19c5 Mon Sep 17 00:00:00 2001 From: Wei-Chiu Chuang Date: Fri, 21 May 2021 09:26:50 -0700 Subject: [PATCH] HADOOP-17718. Explicitly set locale in the Dockerfile. (#3034) Reviewed-by: Akira Ajisaka --- dev-support/docker/Dockerfile | 4 ++++ dev-support/docker/Dockerfile_aarch64 | 4 ++++ dev-support/docker/Dockerfile_centos_7 | 4 ++++ dev-support/docker/Dockerfile_centos_8 | 4 ++++ 4 files changed, 16 insertions(+) diff --git a/dev-support/docker/Dockerfile b/dev-support/docker/Dockerfile index 51743039e0..ef2f156261 100644 --- a/dev-support/docker/Dockerfile +++ b/dev-support/docker/Dockerfile @@ -85,6 +85,10 @@ RUN apt-get -q update \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* +RUN locale-gen en_US.UTF-8 +ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8' +ENV PYTHONIOENCODING=utf-8 + ###### # Set env vars required to build Hadoop ###### diff --git a/dev-support/docker/Dockerfile_aarch64 b/dev-support/docker/Dockerfile_aarch64 index 362c5466a4..710c989c7b 100644 --- a/dev-support/docker/Dockerfile_aarch64 +++ b/dev-support/docker/Dockerfile_aarch64 @@ -89,6 +89,10 @@ RUN apt-get -q update \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* +RUN locale-gen en_US.UTF-8 +ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8' +ENV PYTHONIOENCODING=utf-8 + ###### # Set env vars required to build Hadoop ###### diff --git a/dev-support/docker/Dockerfile_centos_7 b/dev-support/docker/Dockerfile_centos_7 index bf95835e81..319942e2f6 100644 --- a/dev-support/docker/Dockerfile_centos_7 +++ b/dev-support/docker/Dockerfile_centos_7 @@ -93,6 +93,10 @@ RUN mkdir -p /opt/zstd /tmp/zstd \ && make install \ && cd /root || exit +RUN locale-gen en_US.UTF-8 +ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8' +ENV PYTHONIOENCODING=utf-8 + ###### # Set env vars required to build Hadoop ###### diff --git a/dev-support/docker/Dockerfile_centos_8 b/dev-support/docker/Dockerfile_centos_8 index ddf60b7fc0..7f1f6b4ac2 100644 --- a/dev-support/docker/Dockerfile_centos_8 +++ b/dev-support/docker/Dockerfile_centos_8 @@ -110,6 +110,10 @@ RUN mkdir -p /opt/zstd /tmp/zstd \ && make install \ && cd /root || exit +RUN locale-gen en_US.UTF-8 +ENV LANG='en_US.UTF-8' LANGUAGE='en_US:en' LC_ALL='en_US.UTF-8' +ENV PYTHONIOENCODING=utf-8 + ###### # Set env vars required to build Hadoop ######