Commit 5a3db5844944ef099ddcfc962fc58491045dc538

Authored by Jacob Vosmaer
2 parents bd8eb47c 259f6478

Merge branch 'sql_ro_cruft' into 'master'

Remove sql_ro helpers

Fixes #25
files/gitlab-cookbooks/gitlab/libraries/chef_server.rb
... ... @@ -48,7 +48,6 @@ module GitLab
48 48 end
49 49  
50 50 GitLab['postgresql']['sql_password'] ||= generate_hex(50)
51   - GitLab['postgresql']['sql_ro_password'] ||= generate_hex(50)
52 51  
53 52 if File.directory?("/etc/gitlab")
54 53 File.open("/etc/gitlab/gitlab-secrets.json", "w") do |f|
... ... @@ -56,7 +55,6 @@ module GitLab
56 55 Chef::JSONCompat.to_json_pretty({
57 56 'postgresql' => {
58 57 'sql_password' => GitLab['postgresql']['sql_password'],
59   - 'sql_ro_password' => GitLab['postgresql']['sql_ro_password']
60 58 },
61 59 })
62 60 )
... ...
files/gitlab-cookbooks/gitlab/libraries/helper.rb
... ... @@ -38,10 +38,6 @@ class PgHelper
38 38 user_exists?(node['gitlab']['postgresql']['sql_user'])
39 39 end
40 40  
41   - def sql_ro_user_exists?
42   - user_exists?(node['gitlab']['postgresql']['sql_ro_user'])
43   - end
44   -
45 41 def user_exists?(db_user)
46 42 psql_cmd(["-d 'template1'",
47 43 "-c 'select usename from pg_user' -A",
... ...