Commit 96055e7fb84591507ef0650944a18b9d2cced7fd
1 parent
e05e8cbd
Exists in
master
and in
17 other branches
Rename GitLab module to Gitlab
Showing
2 changed files
with
8 additions
and
8 deletions
Show diff stats
files/gitlab-cookbooks/gitlab/libraries/gitlab.rb
@@ -21,7 +21,7 @@ require 'chef/json_compat' | @@ -21,7 +21,7 @@ require 'chef/json_compat' | ||
21 | require 'chef/mixin/deep_merge' | 21 | require 'chef/mixin/deep_merge' |
22 | require 'securerandom' | 22 | require 'securerandom' |
23 | 23 | ||
24 | -module GitLab | 24 | +module Gitlab |
25 | extend(Mixlib::Config) | 25 | extend(Mixlib::Config) |
26 | 26 | ||
27 | bootstrap Mash.new | 27 | bootstrap Mash.new |
@@ -43,18 +43,18 @@ module GitLab | @@ -43,18 +43,18 @@ module GitLab | ||
43 | end | 43 | end |
44 | existing_secrets.each do |k, v| | 44 | existing_secrets.each do |k, v| |
45 | v.each do |pk, p| | 45 | v.each do |pk, p| |
46 | - GitLab[k][pk] = p | 46 | + Gitlab[k][pk] = p |
47 | end | 47 | end |
48 | end | 48 | end |
49 | 49 | ||
50 | - GitLab['postgresql']['sql_password'] ||= generate_hex(50) | 50 | + Gitlab['postgresql']['sql_password'] ||= generate_hex(50) |
51 | 51 | ||
52 | if File.directory?("/etc/gitlab") | 52 | if File.directory?("/etc/gitlab") |
53 | File.open("/etc/gitlab/gitlab-secrets.json", "w") do |f| | 53 | File.open("/etc/gitlab/gitlab-secrets.json", "w") do |f| |
54 | f.puts( | 54 | f.puts( |
55 | Chef::JSONCompat.to_json_pretty({ | 55 | Chef::JSONCompat.to_json_pretty({ |
56 | 'postgresql' => { | 56 | 'postgresql' => { |
57 | - 'sql_password' => GitLab['postgresql']['sql_password'], | 57 | + 'sql_password' => Gitlab['postgresql']['sql_password'], |
58 | }, | 58 | }, |
59 | }) | 59 | }) |
60 | ) | 60 | ) |
@@ -71,7 +71,7 @@ module GitLab | @@ -71,7 +71,7 @@ module GitLab | ||
71 | "postgresql" | 71 | "postgresql" |
72 | ].each do |key| | 72 | ].each do |key| |
73 | rkey = key.gsub('_', '-') | 73 | rkey = key.gsub('_', '-') |
74 | - results['gitlab'][rkey] = GitLab[key] | 74 | + results['gitlab'][rkey] = Gitlab[key] |
75 | end | 75 | end |
76 | 76 | ||
77 | results | 77 | results |
files/gitlab-cookbooks/gitlab/recipes/default.rb
@@ -26,11 +26,11 @@ directory "/etc/gitlab" do | @@ -26,11 +26,11 @@ directory "/etc/gitlab" do | ||
26 | action :nothing | 26 | action :nothing |
27 | end.run_action(:create) | 27 | end.run_action(:create) |
28 | 28 | ||
29 | -GitLab[:node] = node | 29 | +Gitlab[:node] = node |
30 | if File.exists?("/etc/gitlab/gitlab.rb") | 30 | if File.exists?("/etc/gitlab/gitlab.rb") |
31 | - GitLab.from_file("/etc/gitlab/gitlab.rb") | 31 | + Gitlab.from_file("/etc/gitlab/gitlab.rb") |
32 | end | 32 | end |
33 | -node.consume_attributes(GitLab.generate_config(node['fqdn'])) | 33 | +node.consume_attributes(Gitlab.generate_config(node['fqdn'])) |
34 | 34 | ||
35 | if File.exists?("/var/opt/gitlab/bootstrapped") | 35 | if File.exists?("/var/opt/gitlab/bootstrapped") |
36 | node.set['gitlab']['bootstrap']['enable'] = false | 36 | node.set['gitlab']['bootstrap']['enable'] = false |