Skip to content

Commit 6a11163

Browse files
author
jtimberman
committed
cook-105, add git server recipe
1 parent ca9e5e3 commit 6a11163

3 files changed

Lines changed: 32 additions & 0 deletions

File tree

‎git/recipes/server.rb‎

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#
2+
# Cookbook Name:: git
3+
# Recipe:: server
4+
#
5+
# Copyright 2009, Opscode
6+
#
7+
# Licensed under the Apache License, Version 2.0 (the "License");
8+
# you may not use this file except in compliance with the License.
9+
# You may obtain a copy of the License at
10+
#
11+
# http://www.apache.org/licenses/LICENSE-2.0
12+
#
13+
# Unless required by applicable law or agreed to in writing, software
14+
# distributed under the License is distributed on an "AS IS" BASIS,
15+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16+
# See the License for the specific language governing permissions and
17+
# limitations under the License.
18+
19+
include_recipe "git"
20+
21+
directory "/srv/git" do
22+
owner "root"
23+
group "root"
24+
mode 0755
25+
end
26+
27+
runit_service "git-daemon"
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/sh
2+
exec svlogd -tt ./main
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
exec 2>&1
3+
exec /usr/bin/git daemon --export-all --user nobody --group daemon --base-path=/srv/git /srv/git

0 commit comments

Comments
 (0)