mirror of
https://ops.gitlab.net/gitlab-org/gitlab-build-images.git
synced 2025-12-10 02:22:57 +01:00
Generate UTF-8 locales and set ENV
http://jaredmarkell.com/docker-and-locales/
This commit is contained in:
parent
66c1a55f98
commit
5d15c62821
5 changed files with 43 additions and 9 deletions
|
|
@ -1,8 +1,14 @@
|
||||||
FROM ruby:2.1
|
FROM ruby:2.1
|
||||||
|
|
||||||
ENV PACKAGES="git-core" \
|
ENV PACKAGES="git-core"
|
||||||
LC_ALL=en_US.UTF-8
|
|
||||||
|
|
||||||
ADD / /
|
ADD / /
|
||||||
RUN /scripts/install-essentials
|
RUN /scripts/install-essentials
|
||||||
|
|
||||||
|
# Set UTF-8 http://jaredmarkell.com/docker-and-locales/
|
||||||
|
# Must be set after install-essentials is run
|
||||||
|
ENV LANG en_US.UTF-8
|
||||||
|
ENV LANGUAGE en_US:en
|
||||||
|
ENV LC_ALL en_US.UTF-8
|
||||||
|
|
||||||
RUN /scripts/install-phantomjs
|
RUN /scripts/install-phantomjs
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,14 @@
|
||||||
FROM ruby:2.2
|
FROM ruby:2.2
|
||||||
|
|
||||||
ENV PACKAGES="git-core" \
|
ENV PACKAGES="git-core"
|
||||||
LC_ALL=en_US.UTF-8
|
|
||||||
|
|
||||||
ADD / /
|
ADD / /
|
||||||
RUN /scripts/install-essentials
|
RUN /scripts/install-essentials
|
||||||
|
|
||||||
|
# Set UTF-8 http://jaredmarkell.com/docker-and-locales/
|
||||||
|
# Must be set after install-essentials is run
|
||||||
|
ENV LANG en_US.UTF-8
|
||||||
|
ENV LANGUAGE en_US:en
|
||||||
|
ENV LC_ALL en_US.UTF-8
|
||||||
|
|
||||||
RUN /scripts/install-phantomjs
|
RUN /scripts/install-phantomjs
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,14 @@
|
||||||
FROM ruby:2.3
|
FROM ruby:2.3
|
||||||
|
|
||||||
ENV PACKAGES="git-core" \
|
ENV PACKAGES="git-core"
|
||||||
LC_ALL=en_US.UTF-8
|
|
||||||
|
|
||||||
ADD / /
|
ADD / /
|
||||||
RUN /scripts/install-essentials
|
RUN /scripts/install-essentials
|
||||||
|
|
||||||
|
# Set UTF-8 http://jaredmarkell.com/docker-and-locales/
|
||||||
|
# Must be set after install-essentials is run
|
||||||
|
ENV LANG en_US.UTF-8
|
||||||
|
ENV LANGUAGE en_US:en
|
||||||
|
ENV LC_ALL en_US.UTF-8
|
||||||
|
|
||||||
RUN /scripts/install-phantomjs
|
RUN /scripts/install-phantomjs
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,14 @@
|
||||||
FROM ruby:2.1
|
FROM ruby:2.1
|
||||||
|
|
||||||
ENV PACKAGES="git-core nodejs pandoc texlive-latex-recommended texlive-xetex texlive-fonts-recommended ed" \
|
ENV PACKAGES="git-core nodejs pandoc texlive-latex-recommended texlive-xetex texlive-fonts-recommended ed"
|
||||||
LC_ALL=en_US.UTF-8
|
|
||||||
|
|
||||||
ADD / /
|
ADD / /
|
||||||
RUN /scripts/install-essentials
|
RUN /scripts/install-essentials
|
||||||
|
|
||||||
|
# Set UTF-8 http://jaredmarkell.com/docker-and-locales/
|
||||||
|
# Must be set after install-essentials is run
|
||||||
|
ENV LANG en_US.UTF-8
|
||||||
|
ENV LANGUAGE en_US:en
|
||||||
|
ENV LC_ALL en_US.UTF-8
|
||||||
|
|
||||||
|
RUN rm -rf /var/lib/apt/lists/*
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ set -xeo pipefail
|
||||||
|
|
||||||
apt-get update
|
apt-get update
|
||||||
apt-get install -y \
|
apt-get install -y \
|
||||||
curl wget build-essential \
|
curl wget build-essential apt-utils locales \
|
||||||
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
|
libssl-dev libyaml-dev libreadline6-dev zlib1g-dev \
|
||||||
libncurses5-dev libffi-dev libgdbm3 libgdbm-dev \
|
libncurses5-dev libffi-dev libgdbm3 libgdbm-dev \
|
||||||
ca-certificates libyaml-dev checkinstall libxml2-dev \
|
ca-certificates libyaml-dev checkinstall libxml2-dev \
|
||||||
|
|
@ -13,4 +13,13 @@ apt-get install -y \
|
||||||
libkrb5-dev postgresql-client mysql-client unzip \
|
libkrb5-dev postgresql-client mysql-client unzip \
|
||||||
$PACKAGES
|
$PACKAGES
|
||||||
|
|
||||||
|
# Set UTF-8
|
||||||
|
# http://stackoverflow.com/a/3182519/2137281
|
||||||
|
LOC=$'LC_ALL=en_US.UTF-8\nLANG=en_US.UTF-8'
|
||||||
|
echo "$LOC" > /etc/environment
|
||||||
|
cat /etc/environment
|
||||||
|
locale-gen "en_US en_US.UTF-8"
|
||||||
|
dpkg-reconfigure locales -f noninteractive -p critical
|
||||||
|
locale -a
|
||||||
|
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue