Commit 86f2f852198ec2e23419f3c892f50188348bf4ec
Exists in
master
and in
17 other branches
Merge branch 'bootstrap_recipe' into 'master'
WIP Enable bootstrap feature and fix runit recipe
Showing
4 changed files
with
42 additions
and
9 deletions
Show diff stats
| @@ -0,0 +1,25 @@ | @@ -0,0 +1,25 @@ | ||
| 1 | +# | ||
| 2 | +# Copyright:: Copyright (c) 2012 Opscode, Inc. | ||
| 3 | +# License:: Apache License, Version 2.0 | ||
| 4 | +# | ||
| 5 | +# Licensed under the Apache License, Version 2.0 (the "License"); | ||
| 6 | +# you may not use this file except in compliance with the License. | ||
| 7 | +# You may obtain a copy of the License at | ||
| 8 | +# | ||
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 | ||
| 10 | +# | ||
| 11 | +# Unless required by applicable law or agreed to in writing, software | ||
| 12 | +# distributed under the License is distributed on an "AS IS" BASIS, | ||
| 13 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| 14 | +# See the License for the specific language governing permissions and | ||
| 15 | +# limitations under the License. | ||
| 16 | +# | ||
| 17 | + | ||
| 18 | +bootstrap_status_file = "/var/opt/gitlab/bootstrapped" | ||
| 19 | + | ||
| 20 | +file bootstrap_status_file do | ||
| 21 | + owner "root" | ||
| 22 | + group "root" | ||
| 23 | + mode "0600" | ||
| 24 | + content "All your bootstraps are belong to Chef" | ||
| 25 | +end |
files/gitlab-cookbooks/gitlab/recipes/bootstrap_disable.rb
0 → 100644
| @@ -0,0 +1,16 @@ | @@ -0,0 +1,16 @@ | ||
| 1 | +# | ||
| 2 | +# Copyright:: Copyright (c) 2012 Opscode, Inc. | ||
| 3 | +# License:: Apache License, Version 2.0 | ||
| 4 | +# | ||
| 5 | +# Licensed under the Apache License, Version 2.0 (the "License"); | ||
| 6 | +# you may not use this file except in compliance with the License. | ||
| 7 | +# You may obtain a copy of the License at | ||
| 8 | +# | ||
| 9 | +# http://www.apache.org/licenses/LICENSE-2.0 | ||
| 10 | +# | ||
| 11 | +# Unless required by applicable law or agreed to in writing, software | ||
| 12 | +# distributed under the License is distributed on an "AS IS" BASIS, | ||
| 13 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| 14 | +# See the License for the specific language governing permissions and | ||
| 15 | +# limitations under the License. | ||
| 16 | +# |
files/gitlab-cookbooks/gitlab/recipes/default.rb
| @@ -53,6 +53,7 @@ include_recipe "runit" | @@ -53,6 +53,7 @@ include_recipe "runit" | ||
| 53 | [ | 53 | [ |
| 54 | "postgresql", | 54 | "postgresql", |
| 55 | "redis", | 55 | "redis", |
| 56 | + "bootstrap", | ||
| 56 | ].each do |service| | 57 | ].each do |service| |
| 57 | if node["gitlab"][service]["enable"] | 58 | if node["gitlab"][service]["enable"] |
| 58 | include_recipe "gitlab::#{service}" | 59 | include_recipe "gitlab::#{service}" |
files/gitlab-cookbooks/runit/recipes/upstart.rb
| @@ -17,15 +17,6 @@ | @@ -17,15 +17,6 @@ | ||
| 17 | # limitations under the License. | 17 | # limitations under the License. |
| 18 | # | 18 | # |
| 19 | 19 | ||
| 20 | -# Ensure the previous named iteration of the system job is nuked | ||
| 21 | -execute "initctl stop gitlab-runsvdir" do | ||
| 22 | - only_if "initctl status gitlab-runsvdir | grep start" | ||
| 23 | - retries 30 | ||
| 24 | -end | ||
| 25 | -file "/etc/init/gitlab-runsvdir.conf" do | ||
| 26 | - action :delete | ||
| 27 | -end | ||
| 28 | - | ||
| 29 | cookbook_file "/etc/init/gitlab-runsvdir.conf" do | 20 | cookbook_file "/etc/init/gitlab-runsvdir.conf" do |
| 30 | owner "root" | 21 | owner "root" |
| 31 | group "root" | 22 | group "root" |