blob: 3d5ee40c7ac94863562ada84db75d0b34b716f6d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-admin/chef/chef-10.16.4.ebuild,v 1.2 2012/12/27 07:13:11 hollow Exp $
EAPI=4
USE_RUBY="ruby18 ruby19"
RUBY_FAKEGEM_TASK_DOC=""
RUBY_FAKEGEM_TASK_TEST="spec"
RUBY_FAKEGEM_EXTRADOC="README.rdoc"
RUBY_FAKEGEM_GEMSPEC=${RUBY_FAKEGEM_NAME}.gemspec
inherit ruby-fakegem user
DESCRIPTION="Chef is a systems integration framework"
HOMEPAGE="http://wiki.opscode.com/display/chef"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
# specs have various indempotency issues which result in the global Chef::Config
# object to be replaced and subsequently fails other specs. Revisit this later.
RESTRICT="test"
ruby_add_rdepend ">=dev-ruby/bunny-0.6.0
dev-ruby/erubis
>=dev-ruby/highline-1.6.9
>=dev-ruby/json-1.4.4
>=dev-ruby/mixlib-authentication-1.3.0
>=dev-ruby/mixlib-cli-1.1.0
>=dev-ruby/mixlib-config-1.1.2
>=dev-ruby/mixlib-log-1.3.0
dev-ruby/mixlib-shellout
<dev-ruby/moneta-0.7.0
>=dev-ruby/net-ssh-2.2.2
<dev-ruby/net-ssh-2.3
>=dev-ruby/net-ssh-multi-1.1
<dev-ruby/net-ssh-multi-1.2
>=dev-ruby/ohai-0.6.0
>=dev-ruby/rest-client-1.0.4
<dev-ruby/rest-client-1.7
dev-ruby/ruby-shadow
>=dev-ruby/treetop-1.4.9
<dev-ruby/treetop-1.5
dev-ruby/uuidtools
>=dev-ruby/yajl-ruby-1.1
<dev-ruby/yajl-ruby-2"
each_ruby_prepare() {
ruby_fakegem_metadata_gemspec ../metadata ${RUBY_FAKEGEM_GEMSPEC}
# bunny
sed -i -e 's/"< 0.8.0", //' ${RUBY_FAKEGEM_GEMSPEC} || die "Unable to fix up dependencies."
# json
sed -i -e 's/"<= 1.6.1", //' ${RUBY_FAKEGEM_GEMSPEC} || die "Unable to fix up dependencies."
}
all_ruby_install() {
all_fakegem_install
keepdir /etc/chef /var/lib/chef /var/log/chef /var/run/chef
doinitd "${FILESDIR}/initd/chef-client"
doconfd "${FILESDIR}/confd/chef-client"
insinto /etc/chef
doins "${FILESDIR}/client.rb"
doins "${FILESDIR}/solo.rb"
doman distro/common/man/man1/*.1
doman distro/common/man/man8/*.8
}
pkg_setup() {
enewgroup chef
enewuser chef -1 -1 /var/lib/chef chef
}
pkg_postinst() {
elog
elog "You should edit /etc/chef/client.rb before starting the service with"
elog "/etc/init.d/chef-client start"
elog
}
|