Do not assume that /var/lib/locales/supported.d/local exist

Since people can generate their own image with debootstrap, and
this wouldn't create a file /var/lib/locales/supported.d/local,
better check if it exist and work if it doesn't.

Fix #656
reviewable/pr18780/r1
Michael Scherer 9 years ago
parent dfdd2bb5ed
commit 1d5afdc139

@ -176,7 +176,7 @@ def main():
state = module.params['state']
if not os.path.exists("/etc/locale.gen"):
if os.path.exists("/var/lib/locales/supported.d/local"):
if os.path.exists("/var/lib/locales/supported.d/"):
# Ubuntu created its own system to manage locales.
ubuntuMode = True
else:

Loading…
Cancel
Save