Skip to content

Commit

Permalink
All locale reqs to postgres script.
Browse files Browse the repository at this point in the history
  • Loading branch information
alanpeabody committed Mar 19, 2014
1 parent 9eedb2e commit e472f87
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions scripts/postgresql.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,24 @@
# Set up locals

if [ ! -f /etc/profile.d/lang.sh ] ; then
touch /etc/profile.d/lang.sh
fi

if grep -lq 'en_US.UTF-8' /etc/profile.d/lang.sh ; then
echo 'Locals set up'
else
echo 'export LANGUAGE="en_US.UTF-8"' >> /etc/profile.d/lang.sh
echo 'export LANG="en_US.UTF-8"' >> /etc/profile.d/lang.sh
echo 'export LC_ALL="en_US.UTF-8"' >> /etc/profile.d/lang.sh

locale-gen en_US.UTF-8
dpkg-reconfigure locales
fi

export LANGUAGE="en_US.UTF-8"
export LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"

# Install postgres
apt-get install -y postgresql libpq-dev postgresql-contrib

Expand Down

0 comments on commit e472f87

Please sign in to comment.