Managing Locale Settings
Managing Locale Settings
A locale is a collection of language and cultural rules used by an operating system and its applications. It controls settings such as message language, character encoding, and lexicographic conventions.
Platform-managed templates use English locale preferences by default. The following workflow shows how to review the current locale configuration and add support for another language inside a container.
On this page
View Available Locales
1Connect to the container
Open Web SSH or another supported shell connection to the required container.
Run the following command to display the locales currently available on the container:
locale -a
Generate a New Locale
Use the localedef utility to add support for another language and character encoding:
sudo localedef -i {language}_{country} -f {codeset} {language}_{country}.{codeset}
Locale Command Parameters
{language}_{country}specifies the language and country codes.{codeset}defines the character-encoding identifier, such asUTF-8.
To review the locale definitions that can be generated, run:
ls /usr/share/i18n/locales
Choose a language and country definition that exists in
/usr/share/i18n/locales, and use a compatible character encoding.
Verify the New Locale
Run the locale-list command again:
locale -a
Application usage: Generating a locale makes it available inside the container. Individual applications may still require their own language or locale configuration.
