Skip to content
Snippets Groups Projects
Commit a66814c7 authored by Santobert's avatar Santobert Committed by Pascal Vizeli
Browse files

Add script to install locale (#25791)

parent 6909235d
No related branches found
No related tags found
Loading
...@@ -13,6 +13,7 @@ LABEL maintainer="Paulus Schoutsen <Paulus@PaulusSchoutsen.nl>" ...@@ -13,6 +13,7 @@ LABEL maintainer="Paulus Schoutsen <Paulus@PaulusSchoutsen.nl>"
#ENV INSTALL_SSOCR no #ENV INSTALL_SSOCR no
#ENV INSTALL_DLIB no #ENV INSTALL_DLIB no
#ENV INSTALL_IPERF3 no #ENV INSTALL_IPERF3 no
#ENV INSTALL_LOCALES no
VOLUME /config VOLUME /config
......
...@@ -14,6 +14,7 @@ LABEL maintainer="Paulus Schoutsen <Paulus@PaulusSchoutsen.nl>" ...@@ -14,6 +14,7 @@ LABEL maintainer="Paulus Schoutsen <Paulus@PaulusSchoutsen.nl>"
#ENV INSTALL_SSOCR no #ENV INSTALL_SSOCR no
#ENV INSTALL_DLIB no #ENV INSTALL_DLIB no
#ENV INSTALL_IPERF3 no #ENV INSTALL_IPERF3 no
#ENV INSTALL_LOCALES no
VOLUME /config VOLUME /config
......
#!/bin/bash
# Sets up locales.
# Stop on errors
set -e
apt-get update
apt-get install -y --no-install-recommends locales
# Set the locale
sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen
locale-gen
...@@ -9,6 +9,7 @@ INSTALL_OPENALPR="${INSTALL_OPENALPR:-yes}" ...@@ -9,6 +9,7 @@ INSTALL_OPENALPR="${INSTALL_OPENALPR:-yes}"
INSTALL_LIBCEC="${INSTALL_LIBCEC:-yes}" INSTALL_LIBCEC="${INSTALL_LIBCEC:-yes}"
INSTALL_SSOCR="${INSTALL_SSOCR:-yes}" INSTALL_SSOCR="${INSTALL_SSOCR:-yes}"
INSTALL_DLIB="${INSTALL_DLIB:-yes}" INSTALL_DLIB="${INSTALL_DLIB:-yes}"
INSTALL_LOCALES="${INSTALL_LOCALES:-yes}"
# Required debian packages for running hass or components # Required debian packages for running hass or components
PACKAGES=( PACKAGES=(
...@@ -70,6 +71,10 @@ if [ "$INSTALL_DLIB" == "yes" ]; then ...@@ -70,6 +71,10 @@ if [ "$INSTALL_DLIB" == "yes" ]; then
pip3 install --no-cache-dir "dlib>=19.5" pip3 install --no-cache-dir "dlib>=19.5"
fi fi
if [ "$INSTALL_LOCALES" == "yes" ]; then
virtualization/Docker/scripts/locales
fi
# Remove packages # Remove packages
apt-get remove -y --purge ${PACKAGES_DEV[@]} apt-get remove -y --purge ${PACKAGES_DEV[@]}
apt-get -y --purge autoremove apt-get -y --purge autoremove
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment