-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
bugThis issue/PR relates to a bugThis issue/PR relates to a bughas_prmodulemodulemodulepluginsplugin (any type)plugin (any type)
Description
Summary
Custom locales won't install because locale_gen does not check /usr/local/share/i18n/SUPPORTED, only /usr/share/i18n/SUPPORTED. /usr/local is the intended path for user defined locales, and is checked by locale-gen itself.
https://manpages.debian.org/trixie/locales/locale-gen.8.en.html#SEE_ALSO
Issue Type
Bug Report
Component Name
locale_gen
Ansible Version
$ ansible --version
ansible [core 2.14.18]
config file = /home/u/provisions/ansible.cfg
configured module search path = ['/home/u/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python3/dist-packages/ansible
ansible collection location = /home/u/.ansible/collections:/usr/share/ansible/collections
executable location = /usr/bin/ansible
python version = 3.11.2 (main, Apr 28 2025, 14:11:48) [GCC 12.2.0] (/usr/bin/python3)
jinja version = 3.1.2
libyaml = TrueCommunity.general Version
$ ansible-galaxy collection list community.general
# /usr/lib/python3/dist-packages/ansible_collections
Collection Version
----------------- -------
community.general 6.6.2Configuration
$ ansible-config dump --only-changed
CONFIG_FILE() = /home/u/provisions/ansible.cfg
DEFAULT_HOST_LIST(/home/u/provisions/ansible.cfg) = ['/home/u/provisions/inventory.yaml']
DEFAULT_STDOUT_CALLBACK(/home/u/provisions/ansible.cfg) = default
DISPLAY_SKIPPED_HOSTS(/home/u/provisions/ansible.cfg) = TrueOS / Environment
Debian 13
Steps to Reproduce
- ansible.builtin.file:
path: /usr/local/share/i18n/locales
state: directory
- ansible.builtin.copy:
src: locale
dest: /usr/local/share/i18n/locales/en_US@iso
- ansible.builtin.lineinfile:
path: /usr/local/share/i18n/SUPPORTED
create: true
line: en_US.UTF-8@iso UTF-8
- community.general.locale_gen:
name:
- en_US.UTF-8@isoExpected Results
Locale en_US.UTF-8@iso to get installed.
Actual Results
TASK [common : community.general.locale_gen] ************************************************************************************
fatal: [192.168.20.106]: FAILED! => {
"changed": false,
"msg": "The locale you've entered is not available on your system."
}Code of Conduct
- I agree to follow the Ansible Code of Conduct
vertexvaar
Metadata
Metadata
Assignees
Labels
bugThis issue/PR relates to a bugThis issue/PR relates to a bughas_prmodulemodulemodulepluginsplugin (any type)plugin (any type)