Skip to content

Commit

Permalink
Build locales only ones (during apt-get install)
Browse files Browse the repository at this point in the history
Signed-off-by: Marcel Bargull <[email protected]>
  • Loading branch information
mbargull committed Oct 17, 2023
1 parent d53f912 commit c32537b
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions images/base-glibc-debian-bash/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ RUN [ ! -f /etc/apt/sources.list ] || sed --in-place= --regexp-extended \
&& \
apt-get update -qq \
&& \
# Add en_US.UTF-8 locale.
printf '%s\n' 'en_US.UTF-8 UTF-8' \
>> /etc/locale.gen \
&& \
DEBIAN_FRONTEND=noninteractive \
apt-get install --yes --no-install-recommends \
$( \
Expand All @@ -29,13 +33,6 @@ RUN [ ! -f /etc/apt/sources.list ] || sed --in-place= --regexp-extended \
openssh-client \
procps \
&& \
# Add en_US.UTF-8 locale.
sed -i \
's/^# *\(en_US.UTF-8\)/\1/' \
/etc/locale.gen \
&& \
locale-gen \
&& \
# Remove "locales" package, but keep the generated locale.
sed -i \
's/\s*rm .*locale-archive$/: &/' \
Expand Down

0 comments on commit c32537b

Please sign in to comment.