]> git.pld-linux.org Git - packages/chef.git/blob - chef.spec
up to 11.8.2
[packages/chef.git] / chef.spec
1 #
2 # NOTE:
3 # - check releases here: https://github.com/opscode/chef/releases
4
5 # Conditional build:
6 %bcond_with     tests           # build without tests
7
8 Summary:        A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure
9 Name:           chef
10 Version:        11.8.2
11 Release:        0.15
12 License:        Apache v2.0
13 Group:          Development/Languages
14 Source0:        http://rubygems.org/downloads/%{name}-%{version}.gem
15 # Source0-md5:  7d3c2e8b98ec8df050d92686f1429d8f
16 Source1:        %{name}.rb
17 Source2:        %{name}.tmpfiles
18 Source3:        https://raw.github.com/stevendanna/knife-hacks/master/shell/knife_completion.sh
19 # Source3-md5:  a4c1e41370be8088a59ddb3b2e7ea397
20 Patch0:         platform-pld.patch
21 Patch1:         FHS.patch
22 Patch2:         https://github.com/glensc/chef/compare/poldek.patch
23 # Patch2-md5:   5a0fc35de33910b41cba4e87dcb4bf9a
24 Patch3:         https://github.com/glensc/chef/compare/pld-knife-boostrap.patch
25 # Patch3-md5:   bfc884469fad7b5aa46341402be5fccd
26 URL:            https://wiki.opscode.com/display/chef/
27 BuildRequires:  rpm-rubyprov
28 BuildRequires:  rpmbuild(macros) >= 1.673
29 BuildRequires:  sed >= 4.0
30 %if %{with tests}
31 BuildRequires:  ruby-abstract
32 BuildRequires:  ruby-mixlib-authentication >= 1.3.0
33 BuildRequires:  ruby-net-ssh-multi >= 1.1.0
34 BuildRequires:  ruby-rack
35 BuildRequires:  ruby-rake
36 #BuildRequires: ruby-rdoc
37 BuildRequires:  ruby-rest-client >= 1.0.4
38 BuildRequires:  ruby-rspec-core < 2.14
39 BuildRequires:  ruby-rspec-core >= 2.13.0
40 BuildRequires:  ruby-rspec-expectations < 2.14
41 BuildRequires:  ruby-rspec-expectations >= 2.13.0
42 BuildRequires:  ruby-rspec-mocks < 2.14
43 BuildRequires:  ruby-rspec-mocks >= 2.13.0
44 #BuildRequires: ruby-rspec_junit_formatter
45 #BuildRequires: ruby-sdoc
46 %endif
47 Requires:       iproute2
48 Requires:       lsb-release
49 Requires:       poldek >= 0.30
50 Requires:       ruby >= 1:1.9.3.429-4
51 Requires:       ruby-diff-lcs < 2
52 Requires:       ruby-diff-lcs >= 1.2
53 Requires:       ruby-diff-lcs >= 1.2.4
54 Requires:       ruby-erubis
55 Requires:       ruby-highline >= 1.6.9
56 Requires:       ruby-json >= 1.4.4
57 Requires:       ruby-mime-types < 2
58 Requires:       ruby-mime-types >= 1.16
59 Requires:       ruby-mixlib-authentication >= 1.3.0
60 Requires:       ruby-mixlib-cli >= 1.3.0
61 Requires:       ruby-mixlib-config < 3
62 Requires:       ruby-mixlib-config >= 2.0
63 Requires:       ruby-mixlib-log >= 1.3.0
64 Requires:       ruby-mixlib-shellout >= 1.2
65 Requires:       ruby-net-ssh >= 2.6
66 Requires:       ruby-net-ssh-multi >= 1.1.0
67 Requires:       ruby-ohai < 7
68 Requires:       ruby-ohai >= 6.0
69 Requires:       ruby-rest-client >= 1.0.4
70 Requires:       ruby-rubygems
71 Requires:       ruby-yajl >= 1.1
72 Suggests:       chef-zero >= 1.6.2
73 BuildArch:      noarch
74 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
75
76 # do not generate python dependency, yum support is optional
77 %define         _noautoreqfiles %{ruby_vendorlibdir}/chef/provider/package/yum-dump.py
78
79 %description
80 A systems integration framework, built to bring the benefits of
81 configuration management to your entire infrastructure.
82
83 %package -n bash-completion-knife
84 Summary:        bash-completion for knife
85 Summary(pl.UTF-8):      bashowe uzupełnianie nazw dla knifea
86 Group:          Applications/Shells
87 Requires:       %{name} >= 0.10
88 Requires:       bash-completion >= 2.0
89
90 %description -n bash-completion-knife
91 This package provides bash-completion for knife.
92
93 %description -n bash-completion-knife -l pl.UTF-8
94 Pakiet ten dostarcza bashowe uzupełnianie nazw dla knifea.
95
96 %package -n knife
97 Summary:        knife - Chef Server API client utility
98 Group:          Development/Languages
99 Requires:       %{name} = %{version}-%{release}
100
101 %description -n knife
102 Knife is a command-line utility used to manage data on a Chef server
103 through the HTTP(S) API. Knife is organized into groups of subcommands
104 centered around the various object types in Chef. Each category of
105 subcommand is documented in its own manual page.
106
107 %prep
108 %setup -q
109 %patch0 -p1
110 %patch1 -p1
111 %patch2 -p1
112 %patch3 -p1
113
114 grep --exclude-dir=spec --exclude-dir=distro -r /var/chef . && exit 1
115
116 %{__sed} -i -e '1 s,#!.*ruby,#!%{__ruby},' bin/*
117
118 %build
119 %if %{with tests}
120 rspec spec
121 %endif
122
123 %install
124 rm -rf $RPM_BUILD_ROOT
125 install -d $RPM_BUILD_ROOT{%{ruby_vendorlibdir},%{_bindir},%{_mandir}/man1,%{systemdtmpfilesdir}} \
126         $RPM_BUILD_ROOT{%{_sysconfdir}/%{name},/var/{run/%{name},cache/%{name},lib/%{name}/{roles,data_bags,environments,backup}}}
127
128 cp -a lib/* $RPM_BUILD_ROOT%{ruby_vendorlibdir}
129 cp -a bin/* $RPM_BUILD_ROOT%{_bindir}
130 cp -a distro/common/man/* $RPM_BUILD_ROOT%{_mandir}
131 %{__rm} $RPM_BUILD_ROOT%{_mandir}/man1/README.md
132
133 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/chef.rb
134 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{systemdtmpfilesdir}/%{name}.conf
135
136 install -d $RPM_BUILD_ROOT%{bash_compdir}
137 cp -p %{SOURCE3} $RPM_BUILD_ROOT%{bash_compdir}/knife
138
139 %clean
140 rm -rf $RPM_BUILD_ROOT
141
142 %files
143 %defattr(644,root,root,755)
144 %doc README.md CONTRIBUTING.md
145 %dir %{_sysconfdir}/%{name}
146 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/chef.rb
147 %attr(755,root,root) %{_bindir}/chef-apply
148 %attr(755,root,root) %{_bindir}/chef-client
149 %attr(755,root,root) %{_bindir}/chef-service-manager
150 %attr(755,root,root) %{_bindir}/chef-shell
151 %attr(755,root,root) %{_bindir}/chef-solo
152 %attr(755,root,root) %{_bindir}/shef
153 %{_mandir}/man1/chef-shell.1*
154 %{_mandir}/man8/chef-client.8*
155 %{_mandir}/man8/chef-solo.8*
156 %{ruby_vendorlibdir}/chef.rb
157 %{ruby_vendorlibdir}/chef
158 %exclude %{ruby_vendorlibdir}/chef/knife
159 %exclude %{ruby_vendorlibdir}/chef/application/knife.rb
160 %exclude %{ruby_vendorlibdir}/chef/chef_fs/knife.rb
161 %exclude %{ruby_vendorlibdir}/chef/knife.rb
162 %{systemdtmpfilesdir}/chef.conf
163
164 %dir /var/lib/%{name}
165 %dir /var/lib/%{name}/roles
166 %dir /var/lib/%{name}/data_bags
167 %dir /var/lib/%{name}/environments
168
169 %dir /var/cache/%{name}
170 %dir /var/run/%{name}
171
172 %files -n knife
173 %defattr(644,root,root,755)
174 %attr(755,root,root) %{_bindir}/knife
175 %{ruby_vendorlibdir}/chef/knife.rb
176 %{ruby_vendorlibdir}/chef/knife
177 %{ruby_vendorlibdir}/chef/application/knife.rb
178 %{ruby_vendorlibdir}/chef/chef_fs/knife.rb
179 %{_mandir}/man1/knife-bootstrap.1*
180 %{_mandir}/man1/knife-client.1*
181 %{_mandir}/man1/knife-configure.1*
182 %{_mandir}/man1/knife-cookbook-site.1*
183 %{_mandir}/man1/knife-cookbook.1*
184 %{_mandir}/man1/knife-data-bag.1*
185 %{_mandir}/man1/knife-delete.1*
186 %{_mandir}/man1/knife-deps.1*
187 %{_mandir}/man1/knife-diff.1*
188 %{_mandir}/man1/knife-download.1*
189 %{_mandir}/man1/knife-edit.1*
190 %{_mandir}/man1/knife-environment.1*
191 %{_mandir}/man1/knife-exec.1*
192 %{_mandir}/man1/knife-index-rebuild.1*
193 %{_mandir}/man1/knife-list.1*
194 %{_mandir}/man1/knife-node.1*
195 %{_mandir}/man1/knife-raw.1*
196 %{_mandir}/man1/knife-recipe-list.1*
197 %{_mandir}/man1/knife-role.1*
198 %{_mandir}/man1/knife-search.1*
199 %{_mandir}/man1/knife-show.1*
200 %{_mandir}/man1/knife-ssh.1*
201 %{_mandir}/man1/knife-status.1*
202 %{_mandir}/man1/knife-tag.1*
203 %{_mandir}/man1/knife-upload.1*
204 %{_mandir}/man1/knife-user.1*
205 %{_mandir}/man1/knife-xargs.1*
206 %{_mandir}/man1/knife.1*
207
208 %dir /var/lib/%{name}
209 %dir /var/lib/%{name}/roles
210 %dir /var/lib/%{name}/data_bags
211 %dir /var/lib/%{name}/environments
212 %dir %attr(750,root,root) /var/lib/%{name}/backup
213
214 %dir /var/cache/%{name}
215 %dir /var/run/%{name}
216
217 %files -n bash-completion-knife
218 %defattr(644,root,root,755)
219 %{bash_compdir}/knife
This page took 0.062878 seconds and 4 git commands to generate.