freeipa/ipaserver/install
Alexander Bokovoy 38a86e3367 systemd: enforce en_US.UTF-8 locale in systemd units
Python code does detection of the system encoding based on the locale
settings. On RHEL 8.4 development images we somehow get LANG=en_US which
defaults to iso8859-1 _inside_ the systemd-started service, even though
the whole environment defaults to LANG=en_US.UTF-8.

When instrumented with ExecStartPre=/usr/bin/locale, the following
output can be seen:

locale[45481]: LANG=en_US
locale[45481]: LC_CTYPE="en_US"
locale[45481]: LC_NUMERIC="en_US"
locale[45481]: LC_TIME="en_US"
locale[45481]: LC_COLLATE="en_US"
locale[45481]: LC_MONETARY="en_US"
locale[45481]: LC_MESSAGES="en_US"
locale[45481]: LC_PAPER="en_US"
locale[45481]: LC_NAME="en_US"
locale[45481]: LC_ADDRESS="en_US"
locale[45481]: LC_TELEPHONE="en_US"
locale[45481]: LC_MEASUREMENT="en_US"
locale[45481]: LC_IDENTIFICATION="en_US"
locale[45481]: LC_ALL=
ipactl[45483]: Unexpected error
ipactl[45483]: SystemEncodingError: System encoding must be UTF-8, 'iso8859-1' is not supported. Set LC_ALL="C.UTF-8", or LC_ALL="" and LC_CTYPE="C.UTF-8".
systemd[1]: ipa.service: Main process exited, code=exited, status=1/FAILURE

Set the environment to explicit LC_ALL=C.UTF-8 to please the Python
code. FreeIPA server side only cares about actual encoding, not the
language itself. We already use LC_ALL=C.UTF-8 in httpd service snippet.

Fixes: https://pagure.io/freeipa/issue/8617
Signed-off-by: Alexander Bokovoy <abokovoy@redhat.com>
Reviewed-By: Thomas Woerner <twoerner@redhat.com>
2020-12-10 14:38:05 +02:00
..
plugins Catch EmptyResult exception in update_idranges 2020-11-06 16:29:41 -05:00
server upgrade: provide DOMAIN to the server upgrade dictionary 2020-12-10 13:47:16 +02:00
__init__.py Remove __all__ specifications in ipaclient and ipaserver.install 2013-09-06 15:42:33 +02:00
adtrust.py Use api.env.container_sysaccounts 2020-04-28 11:28:29 +02:00
adtrustinstance.py uninstall: Don't fail on missing /var/lib/samba 2020-08-17 10:46:23 +02:00
bindinstance.py Don't add 127.0.0.1 to resolv.conf twice 2020-10-08 08:32:08 +02:00
ca.py Don't restart certmonger after stopping tracking in uninstall 2020-10-19 12:56:22 -04:00
cainstance.py systemd: enforce en_US.UTF-8 locale in systemd units 2020-12-10 14:38:05 +02:00
certs.py Set mode of /etc/ipa/ca.crt to 0644 in CA-less installations 2020-08-06 12:49:51 +02:00
conncheck.py install: introduce installer class hierarchy 2016-11-11 12:17:25 +01:00
custodiainstance.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
dns.py Use new API for auto-forwarders 2020-09-23 16:44:26 +02:00
dnskeysyncinstance.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
dogtag.py Verify pki ini override early 2019-04-10 13:43:23 +02:00
dogtaginstance.py Improve PKI subsystem detection 2020-12-09 09:54:58 +01:00
dsinstance.py Skip offline dse.ldif patching by default 2020-10-05 15:02:14 +02:00
httpinstance.py Clean up entire /run/ipa/ccaches directory not just files 2020-09-23 14:48:29 +02:00
installutils.py Unify access to FQDN 2020-10-26 17:11:19 +11:00
ipa_acme_manage.py ipa-acme-manage: user a cookie created for the communication with dogtag REST endpoints 2020-11-17 18:48:24 +02:00
ipa_backup.py Always define the path DNSSEC_OPENSSL_CONF 2020-11-30 15:52:19 +01:00
ipa_cacert_manage.py lint: Make Pylint-2.4 happy again 2020-02-12 18:08:32 +02:00
ipa_cert_fix.py Create a common place to retrieve facts about an IPA installation 2020-08-06 14:11:27 +02:00
ipa_crlgen_manage.py CRL generation master: new utility to enable|disable 2019-03-14 09:39:55 +01:00
ipa_kra_install.py Fix E722 do not use bare 'except' 2020-05-05 10:42:46 +02:00
ipa_ldap_updater.py Simplify LDAPUpdater 2020-09-22 09:21:00 -04:00
ipa_otptoken_import.py Py3: Remove subclassing from object 2018-09-27 11:49:04 +02:00
ipa_pkinit_manage.py PKINIT: fix ipa-pkinit-manage enable|disable 2018-12-05 11:06:21 +01:00
ipa_replica_install.py Enable replica install info logging to match ipa-server-install 2018-11-01 13:08:58 +01:00
ipa_restore.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
ipa_server_certinstall.py Require an ipa-ca SAN on 3rd party certs if ACME is enabled 2020-11-02 14:01:05 -05:00
ipa_server_install.py Improve console logging for ipa-server-install 2018-06-20 08:38:03 +02:00
ipa_server_upgrade.py ipa commands: print 'IPA is not configured' when ipa is not setup 2018-08-23 12:08:45 +02:00
ipa_trust_enable_agent.py ipa-adtrust-install: run remote configuration for new agents 2020-03-05 14:40:58 +01:00
ipa_winsync_migrate.py ipa commands: print 'IPA is not configured' when ipa is not setup 2018-08-23 12:08:45 +02:00
ipactl.py Create a common place to retrieve facts about an IPA installation 2020-08-06 14:11:27 +02:00
kra.py named: Allow using of a custom OpenSSL engine for BIND 2020-08-31 09:42:31 +03:00
krainstance.py Change KRA profiles in certmonger tracking so they can renew 2020-12-01 12:56:03 +01:00
krbinstance.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
ldapupdate.py Remove magic sleep from create_index_task 2020-10-05 15:02:14 +02:00
odsexporterinstance.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
opendnssecinstance.py Add user and group wrappers 2020-09-22 09:23:18 -04:00
otpdinstance.py Enable pylint missing-final-newline check 2015-12-23 07:59:22 +01:00
replication.py Accept 389-ds JSON replication status messages 2020-12-01 08:45:07 +01:00
schemaupdate.py Unify access to FQDN 2020-10-26 17:11:19 +11:00
service.py Enable importing LDIF files not shipped by IPA 2020-11-02 10:43:57 -05:00
sysupgrade.py Add absolute_import future imports 2018-04-20 09:43:37 +02:00
upgradeinstance.py Move where the restore state is marked during IPA server upgrade 2020-12-02 14:08:51 +02:00