OSDN Git Service

updates roles.
[metasearch/grid-chef-repo.git] / roles / gitlab-on-docker.rb
1 #
2 # Copyright 2017, whitestar
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 #     http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 #
16
17 name 'gitlab-on-docker'
18 description 'GitLab on Docker'
19
20 #gitlab_cn = 'gitlab.io.example.com'  # default: node['fqdn']
21 #gitlab_http_port = '80'  # default: 80, and 8080 already in use.
22 #gitlab_ssh_port = '2022'
23
24 run_list(
25   'role[docker]',
26   'recipe[gitlab-grid::docker-compose]',
27 )
28
29 #env_run_lists()
30
31 #default_attributes()
32
33 override_attributes(
34   'docker-grid' => {
35     'engine' => {
36       'skip_setup' => false,
37     },
38     'compose' => {
39       'skip_setup' => false,
40     },
41   },
42   'gitlab-grid' => {
43     'gitlab.rb' => {
44       #'external_url' => "http://#{gitlab_cn}:#{gitlab_http_port}",
45       'gitlab_rails' => {
46         #'time_zone' => 'Asia/Tokyo',
47         #'gitlab_shell_ssh_port' => gitlab_ssh_port.to_i,
48       },
49     },
50     'docker-compose' => {
51       'config' => {
52         'services' => {
53           'gitlab' => {
54             #'hostname' => gitlab_cn,
55             #'ports' => [
56               #"#{gitlab_http_port}:#{gitlab_http_port}",
57               #"#{gitlab_ssh_port}:22",
58             #],
59           },
60         },
61       },
62     },
63   },
64 )