0

I am trying to set up a component as Docker. The component checks if locale is set up correctly otherwise the component installation fails. In my case locale is throwing below error while building docker on Sles 12

locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=en_US.UTF-8

I have tried to set up the LANG environment variable in Dockerfile, still doesn't help What should i do to fix this?

asolanki
  • 1,333
  • 11
  • 18

1 Answers1

0

As mentioned in the link below by default all locales are not available to reduce the size of the image.

You can install all locales using

zypper -n in -f glibc-locale

https://github.com/openSUSE/docker-containers-build/issues/12

asolanki
  • 1,333
  • 11
  • 18