]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
lxc-debian: don't write C.* locales to /etc/locale.gen
authorAntonio Terceiro <terceiro@debian.org>
Fri, 27 Oct 2017 19:13:54 +0000 (17:13 -0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Thu, 9 Nov 2017 00:14:55 +0000 (01:14 +0100)
Doing that confuses locale generation. lxc-ubuntu does the same check

Signed-off-by: Antonio Terceiro <terceiro@debian.org>
templates/lxc-debian.in

index d02ca7013b1b125bc2f9d13bbeb9dcc6e2c54fbc..28a51433da4da8de59e4da3e23ca3287fd45e3d2 100644 (file)
@@ -99,7 +99,7 @@ EOF
     # reconfigure some services
 
     # but first reconfigure locales - so we get no noisy perl-warnings
-    if [ -z "$LANG" ]; then
+    if [ -z "$LANG" ] || echo $LANG | grep -E -q "^C(\..+)*$"; then
         cat >> "$rootfs/etc/locale.gen" << EOF
 en_US.UTF-8 UTF-8
 EOF