]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
lxc-gentoo, fix lack of any generated locale
authorGuillaume ZITTA <lxc@zitta.fr>
Tue, 1 Apr 2014 21:48:51 +0000 (23:48 +0200)
committerStéphane Graber <stgraber@ubuntu.com>
Wed, 2 Apr 2014 14:50:59 +0000 (10:50 -0400)
fix lack of any generated locale

Signed-off-by: Guillaume ZITTA <lxc@zitta.fr>
Acked-by: Stéphane Graber <stgraber@ubuntu.com>
templates/lxc-gentoo.in

index de427dd8ac071117660e42a3b1427346c961e856..d975f789a4b9e239d874f13bba3a606d642b1f41 100644 (file)
@@ -129,6 +129,7 @@ cache_setup(){
     cache_net && \
     cache_dev && \
     cache_openrc && \
+    cache_locale && \
     rm -rf "${cachefs}" && \
     mv "${partialfs}" "${cachefs}" && \
     printf "###### cache_setup: Cache should be ready\n"
@@ -257,6 +258,16 @@ cache_openrc()
     return 0
 }
 
+cache_locale()
+{
+   printf "### cache_locale(): initiating minimale locale en_US.UTF-8 \n"
+
+   echo "en_US.UTF-8 UTF-8" >> "${partialfs}/etc/locale.gen"
+   chroot "${partialfs}" locale-gen
+
+   return 0
+}
+
 ################################################################################
 #                    CONTAINER Preparation
 ################################################################################