[CHEF-3283] Fixes locale problems in Ubuntu 12.04 that prevents installation of postgresql #7

Closed
wants to merge 1 commit into
from

Projects

None yet

5 participants

@liangzan

https://tickets.opscode.com/browse/CHEF-3283

I'm applying the fix as shown here

http://serverfault.com/questions/384324/postgres-used-in-ubuntu-12-04

It may be related to pull request #1

Applying the recipe before postgresql installation worked for me on a vanilla rackspace Ubuntu 12 instance. Otherwise the default recipe always fail as illustrated in the ServerFault page.

@jesseadams

@liangzan - You still need to sign the CLA and mark the ticket as "Fix Provided." Please see http://wiki.opscode.com/display/chef/How+to+Contribute for more information.

@artofhuman

👍

@btm btm commented on the diff Sep 25, 2013
recipes/fix_locale.rb
@@ -0,0 +1,7 @@
+execute :fix_locale do
+ command 'export LANGUAGE=en_US.UTF-8'
+ command 'export LANG=en_US.UTF-8'
+ command 'export LC_ALL=en_US.UTF-8'
+ command 'locale-gen en_US.UTF-8'
+ command 'sudo dpkg-reconfigure locales'
@btm
btm Sep 25, 2013

If we're running Chef as root, why sudo?

@btm btm commented on the diff Sep 25, 2013
recipes/fix_locale.rb
@@ -0,0 +1,7 @@
+execute :fix_locale do
+ command 'export LANGUAGE=en_US.UTF-8'
+ command 'export LANG=en_US.UTF-8'
+ command 'export LC_ALL=en_US.UTF-8'
+ command 'locale-gen en_US.UTF-8'
@btm
btm Sep 25, 2013

Generally forcing locales runs into problems down the road for people who are in other locales. Is this really the correct thing to do?

@prometheanfire prometheanfire referenced this pull request in rackspace-cookbooks/rackops_rolebook Feb 11, 2014
Closed

need a recipe that sets locales for us #4

@dje

We've decide to close this since we believe managing the locale is outside the scope of this cookbook. Related: #84

@dje dje closed this Apr 21, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment