]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | # |
2 | # spec file for package ceph | |
3 | # | |
11fdf7f2 | 4 | # Copyright (C) 2004-2019 The Ceph Project Developers. See COPYING file |
7c673cae FG |
5 | # at the top-level directory of this distribution and at |
6 | # https://github.com/ceph/ceph/blob/master/COPYING | |
7 | # | |
8 | # All modifications and additions to the file contributed by third parties | |
9 | # remain the property of their copyright owners, unless otherwise agreed | |
10 | # upon. | |
11 | # | |
12 | # This file is under the GNU Lesser General Public License, version 2.1 | |
13 | # | |
14 | # Please submit bugfixes or comments via http://tracker.ceph.com/ | |
d2e6a577 | 15 | # |
11fdf7f2 TL |
16 | |
17 | ################################################################################# | |
18 | # conditional build section | |
19 | # | |
20 | # please read http://rpm.org/user_doc/conditional_builds.html for explanation of | |
21 | # bcond syntax! | |
22 | ################################################################################# | |
7c673cae | 23 | %bcond_with make_check |
f67539c2 | 24 | %bcond_with zbd |
9f95a23c | 25 | %bcond_with cmake_verbose_logging |
eafe8130 | 26 | %bcond_without ceph_test_package |
f67539c2 | 27 | %ifarch s390 |
7c673cae | 28 | %bcond_with tcmalloc |
31f18b77 FG |
29 | %else |
30 | %bcond_without tcmalloc | |
7c673cae | 31 | %endif |
7c673cae FG |
32 | %if 0%{?fedora} || 0%{?rhel} |
33 | %bcond_without selinux | |
f67539c2 TL |
34 | %ifarch x86_64 ppc64le |
35 | %bcond_without rbd_rwl_cache | |
36 | %bcond_without rbd_ssd_cache | |
37 | %global _system_pmdk 1 | |
38 | %else | |
39 | %bcond_with rbd_rwl_cache | |
40 | %bcond_with rbd_ssd_cache | |
41 | %endif | |
9f95a23c TL |
42 | %if 0%{?rhel} >= 8 |
43 | %bcond_with cephfs_java | |
44 | %else | |
11fdf7f2 | 45 | %bcond_without cephfs_java |
9f95a23c TL |
46 | %endif |
47 | %bcond_without amqp_endpoint | |
48 | %bcond_without kafka_endpoint | |
11fdf7f2 TL |
49 | %bcond_without lttng |
50 | %bcond_without libradosstriper | |
51 | %bcond_without ocf | |
11fdf7f2 | 52 | %global _remote_tarball_prefix https://download.ceph.com/tarballs/ |
7c673cae FG |
53 | %endif |
54 | %if 0%{?suse_version} | |
11fdf7f2 | 55 | %bcond_with amqp_endpoint |
1911f103 | 56 | %bcond_with cephfs_java |
9f95a23c | 57 | %bcond_with kafka_endpoint |
11fdf7f2 | 58 | %bcond_with libradosstriper |
11fdf7f2 | 59 | %ifarch x86_64 aarch64 ppc64le |
7c673cae | 60 | %bcond_without lttng |
f67539c2 TL |
61 | %global _system_pmdk 1 |
62 | %bcond_without rbd_rwl_cache | |
63 | %bcond_without rbd_ssd_cache | |
11fdf7f2 TL |
64 | %else |
65 | %bcond_with lttng | |
f67539c2 TL |
66 | %global _system_pmdk 0 |
67 | %bcond_with rbd_rwl_cache | |
68 | %bcond_with rbd_ssd_cache | |
11fdf7f2 | 69 | %endif |
1911f103 TL |
70 | %bcond_with ocf |
71 | %bcond_with selinux | |
72 | #Compat macro for _fillupdir macro introduced in Nov 2017 | |
73 | %if ! %{defined _fillupdir} | |
74 | %global _fillupdir /var/adm/fillup-templates | |
75 | %endif | |
11fdf7f2 TL |
76 | %endif |
77 | %bcond_with seastar | |
f67539c2 | 78 | %bcond_with jaeger |
11fdf7f2 TL |
79 | %if 0%{?fedora} || 0%{?suse_version} >= 1500 |
80 | # distros that ship cmd2 and/or colorama | |
81 | %bcond_without cephfs_shell | |
82 | %else | |
83 | # distros that do _not_ ship cmd2/colorama | |
84 | %bcond_with cephfs_shell | |
85 | %endif | |
9f95a23c TL |
86 | %if 0%{?fedora} || 0%{?suse_version} || 0%{?rhel} >= 8 |
87 | %global weak_deps 1 | |
7c673cae | 88 | %endif |
7c673cae FG |
89 | %if %{with selinux} |
90 | # get selinux policy version | |
9f95a23c TL |
91 | # Force 0.0.0 policy version for centos builds to avoid repository sync issues between rhel and centos |
92 | %if 0%{?centos} | |
93 | %global _selinux_policy_version 0.0.0 | |
94 | %else | |
91327a77 | 95 | %{!?_selinux_policy_version: %global _selinux_policy_version 0.0.0} |
7c673cae | 96 | %endif |
9f95a23c | 97 | %endif |
7c673cae | 98 | |
f67539c2 TL |
99 | %if 0%{?suse_version} |
100 | %if !0%{?is_opensuse} | |
101 | # SLE does not support luarocks | |
102 | %bcond_with lua_packages | |
103 | %else | |
104 | %global luarocks_package_name lua53-luarocks | |
105 | %bcond_without lua_packages | |
106 | %endif | |
107 | %else | |
108 | %global luarocks_package_name luarocks | |
109 | %bcond_without lua_packages | |
110 | %endif | |
111 | ||
7c673cae FG |
112 | %{!?_udevrulesdir: %global _udevrulesdir /lib/udev/rules.d} |
113 | %{!?tmpfiles_create: %global tmpfiles_create systemd-tmpfiles --create} | |
114 | %{!?python3_pkgversion: %global python3_pkgversion 3} | |
eafe8130 | 115 | %{!?python3_version_nodots: %global python3_version_nodots 3} |
11fdf7f2 | 116 | %{!?python3_version: %global python3_version 3} |
7c673cae FG |
117 | |
118 | # disable dwz which compresses the debuginfo | |
119 | %global _find_debuginfo_dwz_opts %{nil} | |
31f18b77 | 120 | |
7c673cae FG |
121 | ################################################################################# |
122 | # main package definition | |
123 | ################################################################################# | |
124 | Name: ceph | |
18d92ca7 | 125 | Version: 16.2.4 |
7c673cae | 126 | Release: 0%{?dist} |
31f18b77 | 127 | %if 0%{?fedora} || 0%{?rhel} |
224ce89b | 128 | Epoch: 2 |
31f18b77 FG |
129 | %endif |
130 | ||
3efd9988 FG |
131 | # define _epoch_prefix macro which will expand to the empty string if epoch is |
132 | # undefined | |
31f18b77 FG |
133 | %global _epoch_prefix %{?epoch:%{epoch}:} |
134 | ||
7c673cae | 135 | Summary: User space components of the Ceph file system |
9f95a23c | 136 | License: LGPL-2.1 and LGPL-3.0 and CC-BY-SA-3.0 and GPL-2.0 and BSL-1.0 and BSD-3-Clause and MIT |
7c673cae FG |
137 | %if 0%{?suse_version} |
138 | Group: System/Filesystems | |
139 | %endif | |
140 | URL: http://ceph.com/ | |
18d92ca7 | 141 | Source0: %{?_remote_tarball_prefix}ceph-16.2.4.tar.bz2 |
7c673cae | 142 | %if 0%{?suse_version} |
11fdf7f2 | 143 | # _insert_obs_source_lines_here |
31f18b77 | 144 | ExclusiveArch: x86_64 aarch64 ppc64le s390x |
7c673cae | 145 | %endif |
7c673cae FG |
146 | ################################################################################# |
147 | # dependencies that apply across all distro families | |
148 | ################################################################################# | |
31f18b77 FG |
149 | Requires: ceph-osd = %{_epoch_prefix}%{version}-%{release} |
150 | Requires: ceph-mds = %{_epoch_prefix}%{version}-%{release} | |
151 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
152 | Requires: ceph-mon = %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
153 | Requires(post): binutils |
154 | %if 0%{with cephfs_java} | |
155 | BuildRequires: java-devel | |
156 | BuildRequires: sharutils | |
157 | %endif | |
158 | %if 0%{with selinux} | |
159 | BuildRequires: checkpolicy | |
160 | BuildRequires: selinux-policy-devel | |
7c673cae | 161 | %endif |
31f18b77 | 162 | BuildRequires: gperf |
11fdf7f2 | 163 | BuildRequires: cmake > 3.5 |
7c673cae FG |
164 | BuildRequires: cryptsetup |
165 | BuildRequires: fuse-devel | |
f67539c2 TL |
166 | %if 0%{with seastar} |
167 | BuildRequires: gcc-toolset-9-gcc-c++ >= 9.2.1-2.3 | |
eafe8130 | 168 | %else |
7c673cae | 169 | BuildRequires: gcc-c++ |
11fdf7f2 | 170 | %endif |
7c673cae FG |
171 | BuildRequires: gdbm |
172 | %if 0%{with tcmalloc} | |
f67539c2 TL |
173 | # libprofiler did not build on ppc64le until 2.7.90 |
174 | %if 0%{?fedora} || 0%{?rhel} >= 8 | |
175 | BuildRequires: gperftools-devel >= 2.7.90 | |
176 | %endif | |
177 | %if 0%{?rhel} && 0%{?rhel} < 8 | |
91327a77 AA |
178 | BuildRequires: gperftools-devel >= 2.6.1 |
179 | %endif | |
180 | %if 0%{?suse_version} | |
7c673cae FG |
181 | BuildRequires: gperftools-devel >= 2.4 |
182 | %endif | |
91327a77 | 183 | %endif |
7c673cae FG |
184 | BuildRequires: leveldb-devel > 1.2 |
185 | BuildRequires: libaio-devel | |
7c673cae | 186 | BuildRequires: libblkid-devel >= 2.17 |
f67539c2 | 187 | BuildRequires: cryptsetup-devel |
7c673cae | 188 | BuildRequires: libcurl-devel |
eafe8130 | 189 | BuildRequires: libcap-ng-devel |
f67539c2 | 190 | BuildRequires: fmt-devel >= 5.2.1 |
9f95a23c | 191 | BuildRequires: pkgconfig(libudev) |
eafe8130 | 192 | BuildRequires: libnl3-devel |
11fdf7f2 | 193 | BuildRequires: liboath-devel |
7c673cae FG |
194 | BuildRequires: libtool |
195 | BuildRequires: libxml2-devel | |
196 | BuildRequires: make | |
11fdf7f2 | 197 | BuildRequires: ncurses-devel |
f67539c2 | 198 | BuildRequires: libicu-devel |
7c673cae | 199 | BuildRequires: parted |
eafe8130 | 200 | BuildRequires: patch |
7c673cae FG |
201 | BuildRequires: perl |
202 | BuildRequires: pkgconfig | |
11fdf7f2 | 203 | BuildRequires: procps |
9f95a23c TL |
204 | BuildRequires: python%{python3_pkgversion} |
205 | BuildRequires: python%{python3_pkgversion}-devel | |
7c673cae | 206 | BuildRequires: snappy-devel |
f67539c2 | 207 | BuildRequires: sqlite-devel |
11fdf7f2 | 208 | BuildRequires: sudo |
9f95a23c | 209 | BuildRequires: pkgconfig(udev) |
7c673cae FG |
210 | BuildRequires: util-linux |
211 | BuildRequires: valgrind-devel | |
31f18b77 | 212 | BuildRequires: which |
7c673cae FG |
213 | BuildRequires: xfsprogs |
214 | BuildRequires: xfsprogs-devel | |
215 | BuildRequires: xmlstarlet | |
f67539c2 TL |
216 | BuildRequires: nasm |
217 | BuildRequires: lua-devel | |
11fdf7f2 TL |
218 | %if 0%{with amqp_endpoint} |
219 | BuildRequires: librabbitmq-devel | |
220 | %endif | |
9f95a23c TL |
221 | %if 0%{with kafka_endpoint} |
222 | BuildRequires: librdkafka-devel | |
223 | %endif | |
f67539c2 TL |
224 | %if 0%{with lua_packages} |
225 | BuildRequires: %{luarocks_package_name} | |
226 | %endif | |
11fdf7f2 TL |
227 | %if 0%{with make_check} |
228 | BuildRequires: jq | |
eafe8130 | 229 | BuildRequires: libuuid-devel |
9f95a23c TL |
230 | BuildRequires: python%{python3_pkgversion}-bcrypt |
231 | BuildRequires: python%{python3_pkgversion}-nose | |
232 | BuildRequires: python%{python3_pkgversion}-pecan | |
233 | BuildRequires: python%{python3_pkgversion}-requests | |
234 | BuildRequires: python%{python3_pkgversion}-dateutil | |
9f95a23c | 235 | BuildRequires: python%{python3_pkgversion}-virtualenv |
9f95a23c | 236 | BuildRequires: python%{python3_pkgversion}-coverage |
9f95a23c | 237 | BuildRequires: python%{python3_pkgversion}-pyOpenSSL |
11fdf7f2 TL |
238 | BuildRequires: socat |
239 | %endif | |
f67539c2 TL |
240 | %if 0%{with zbd} |
241 | BuildRequires: libzbd-devel | |
242 | %endif | |
243 | %if 0%{with jaeger} | |
244 | BuildRequires: bison | |
245 | BuildRequires: flex | |
246 | %if 0%{?fedora} || 0%{?rhel} | |
247 | BuildRequires: json-devel | |
248 | %endif | |
249 | %if 0%{?suse_version} | |
250 | BuildRequires: nlohmann_json-devel | |
251 | %endif | |
252 | BuildRequires: libevent-devel | |
253 | BuildRequires: yaml-cpp-devel | |
254 | %endif | |
255 | %if 0%{?_system_pmdk} | |
256 | BuildRequires: libpmem-devel | |
257 | BuildRequires: libpmemobj-devel | |
258 | %endif | |
11fdf7f2 TL |
259 | %if 0%{with seastar} |
260 | BuildRequires: c-ares-devel | |
261 | BuildRequires: gnutls-devel | |
262 | BuildRequires: hwloc-devel | |
263 | BuildRequires: libpciaccess-devel | |
264 | BuildRequires: lksctp-tools-devel | |
265 | BuildRequires: protobuf-devel | |
266 | BuildRequires: ragel | |
267 | BuildRequires: systemtap-sdt-devel | |
268 | BuildRequires: yaml-cpp-devel | |
f67539c2 TL |
269 | %if 0%{?fedora} |
270 | BuildRequires: libubsan | |
271 | BuildRequires: libasan | |
272 | BuildRequires: libatomic | |
273 | %endif | |
274 | %if 0%{?rhel} | |
275 | BuildRequires: gcc-toolset-9-annobin | |
276 | BuildRequires: gcc-toolset-9-libubsan-devel | |
277 | BuildRequires: gcc-toolset-9-libasan-devel | |
278 | BuildRequires: gcc-toolset-9-libatomic-devel | |
279 | %endif | |
11fdf7f2 | 280 | %endif |
7c673cae FG |
281 | ################################################################################# |
282 | # distro-conditional dependencies | |
283 | ################################################################################# | |
284 | %if 0%{?suse_version} | |
285 | BuildRequires: pkgconfig(systemd) | |
286 | BuildRequires: systemd-rpm-macros | |
7c673cae FG |
287 | %{?systemd_requires} |
288 | PreReq: %fillup_prereq | |
eafe8130 | 289 | BuildRequires: fdupes |
7c673cae FG |
290 | BuildRequires: net-tools |
291 | BuildRequires: libbz2-devel | |
7c673cae FG |
292 | BuildRequires: mozilla-nss-devel |
293 | BuildRequires: keyutils-devel | |
294 | BuildRequires: libopenssl-devel | |
295 | BuildRequires: lsb-release | |
296 | BuildRequires: openldap2-devel | |
11fdf7f2 TL |
297 | #BuildRequires: krb5 |
298 | #BuildRequires: krb5-devel | |
299 | BuildRequires: cunit-devel | |
9f95a23c TL |
300 | BuildRequires: python%{python3_pkgversion}-setuptools |
301 | BuildRequires: python%{python3_pkgversion}-Cython | |
302 | BuildRequires: python%{python3_pkgversion}-PrettyTable | |
303 | BuildRequires: python%{python3_pkgversion}-Sphinx | |
31f18b77 | 304 | BuildRequires: rdma-core-devel |
11fdf7f2 | 305 | BuildRequires: liblz4-devel >= 1.7 |
81eedcae TL |
306 | # for prometheus-alerts |
307 | BuildRequires: golang-github-prometheus-prometheus | |
7c673cae | 308 | %endif |
d2e6a577 | 309 | %if 0%{?fedora} || 0%{?rhel} |
7c673cae FG |
310 | Requires: systemd |
311 | BuildRequires: boost-random | |
7c673cae FG |
312 | BuildRequires: nss-devel |
313 | BuildRequires: keyutils-libs-devel | |
31f18b77 | 314 | BuildRequires: libibverbs-devel |
11fdf7f2 | 315 | BuildRequires: librdmacm-devel |
7c673cae | 316 | BuildRequires: openldap-devel |
11fdf7f2 | 317 | #BuildRequires: krb5-devel |
7c673cae | 318 | BuildRequires: openssl-devel |
11fdf7f2 | 319 | BuildRequires: CUnit-devel |
7c673cae | 320 | BuildRequires: redhat-lsb-core |
11fdf7f2 TL |
321 | BuildRequires: python%{python3_pkgversion}-devel |
322 | BuildRequires: python%{python3_pkgversion}-setuptools | |
323 | BuildRequires: python%{python3_pkgversion}-Cython | |
9f95a23c TL |
324 | BuildRequires: python%{python3_pkgversion}-prettytable |
325 | BuildRequires: python%{python3_pkgversion}-sphinx | |
11fdf7f2 TL |
326 | BuildRequires: lz4-devel >= 1.7 |
327 | %endif | |
328 | # distro-conditional make check dependencies | |
329 | %if 0%{with make_check} | |
330 | %if 0%{?fedora} || 0%{?rhel} | |
f67539c2 | 331 | BuildRequires: golang-github-prometheus |
9f95a23c TL |
332 | BuildRequires: libtool-ltdl-devel |
333 | BuildRequires: xmlsec1 | |
334 | BuildRequires: xmlsec1-devel | |
335 | %ifarch x86_64 | |
336 | BuildRequires: xmlsec1-nss | |
337 | %endif | |
338 | BuildRequires: xmlsec1-openssl | |
339 | BuildRequires: xmlsec1-openssl-devel | |
9f95a23c TL |
340 | BuildRequires: python%{python3_pkgversion}-cherrypy |
341 | BuildRequires: python%{python3_pkgversion}-jwt | |
342 | BuildRequires: python%{python3_pkgversion}-routes | |
343 | BuildRequires: python%{python3_pkgversion}-scipy | |
344 | BuildRequires: python%{python3_pkgversion}-werkzeug | |
9f95a23c TL |
345 | BuildRequires: python%{python3_pkgversion}-pyOpenSSL |
346 | %endif | |
11fdf7f2 | 347 | %if 0%{?suse_version} |
f67539c2 | 348 | BuildRequires: golang-github-prometheus-prometheus |
9f95a23c TL |
349 | BuildRequires: libxmlsec1-1 |
350 | BuildRequires: libxmlsec1-nss1 | |
351 | BuildRequires: libxmlsec1-openssl1 | |
352 | BuildRequires: python%{python3_pkgversion}-CherryPy | |
353 | BuildRequires: python%{python3_pkgversion}-PyJWT | |
354 | BuildRequires: python%{python3_pkgversion}-Routes | |
355 | BuildRequires: python%{python3_pkgversion}-Werkzeug | |
356 | BuildRequires: python%{python3_pkgversion}-numpy-devel | |
357 | BuildRequires: xmlsec1-devel | |
358 | BuildRequires: xmlsec1-openssl-devel | |
11fdf7f2 | 359 | %endif |
7c673cae FG |
360 | %endif |
361 | # lttng and babeltrace for rbd-replay-prep | |
362 | %if %{with lttng} | |
363 | %if 0%{?fedora} || 0%{?rhel} | |
364 | BuildRequires: lttng-ust-devel | |
365 | BuildRequires: libbabeltrace-devel | |
366 | %endif | |
367 | %if 0%{?suse_version} | |
368 | BuildRequires: lttng-ust-devel | |
369 | BuildRequires: babeltrace-devel | |
370 | %endif | |
371 | %endif | |
7c673cae FG |
372 | %if 0%{?suse_version} |
373 | BuildRequires: libexpat-devel | |
7c673cae FG |
374 | %endif |
375 | %if 0%{?rhel} || 0%{?fedora} | |
376 | BuildRequires: expat-devel | |
7c673cae FG |
377 | %endif |
378 | #hardened-cc1 | |
379 | %if 0%{?fedora} || 0%{?rhel} | |
380 | BuildRequires: redhat-rpm-config | |
381 | %endif | |
11fdf7f2 TL |
382 | %if 0%{with seastar} |
383 | %if 0%{?fedora} || 0%{?rhel} | |
384 | BuildRequires: cryptopp-devel | |
385 | BuildRequires: numactl-devel | |
386 | BuildRequires: protobuf-compiler | |
387 | %endif | |
388 | %if 0%{?suse_version} | |
389 | BuildRequires: libcryptopp-devel | |
390 | BuildRequires: libnuma-devel | |
391 | %endif | |
392 | %endif | |
9f95a23c TL |
393 | %if 0%{?rhel} >= 8 |
394 | BuildRequires: /usr/bin/pathfix.py | |
395 | %endif | |
7c673cae FG |
396 | |
397 | %description | |
398 | Ceph is a massively scalable, open-source, distributed storage system that runs | |
399 | on commodity hardware and delivers object, block and file system storage. | |
400 | ||
401 | ||
402 | ################################################################################# | |
403 | # subpackages | |
404 | ################################################################################# | |
405 | %package base | |
406 | Summary: Ceph Base Package | |
407 | %if 0%{?suse_version} | |
408 | Group: System/Filesystems | |
409 | %endif | |
11fdf7f2 | 410 | Provides: ceph-test:/usr/bin/ceph-kvstore-tool |
31f18b77 FG |
411 | Requires: ceph-common = %{_epoch_prefix}%{version}-%{release} |
412 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} | |
413 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} | |
414 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} | |
415 | Requires: librgw2 = %{_epoch_prefix}%{version}-%{release} | |
7c673cae | 416 | %if 0%{with selinux} |
31f18b77 | 417 | Requires: ceph-selinux = %{_epoch_prefix}%{version}-%{release} |
7c673cae | 418 | %endif |
11fdf7f2 | 419 | Requires: cryptsetup |
91327a77 | 420 | Requires: e2fsprogs |
11fdf7f2 TL |
421 | Requires: findutils |
422 | Requires: grep | |
7c673cae | 423 | Requires: logrotate |
91327a77 | 424 | Requires: parted |
7c673cae | 425 | Requires: psmisc |
9f95a23c | 426 | Requires: python%{python3_pkgversion}-setuptools |
11fdf7f2 TL |
427 | Requires: util-linux |
428 | Requires: xfsprogs | |
7c673cae | 429 | Requires: which |
f67539c2 | 430 | %if 0%{?rhel} && 0%{?rhel} < 8 |
91327a77 AA |
431 | # The following is necessary due to tracker 36508 and can be removed once the |
432 | # associated upstream bugs are resolved. | |
433 | %if 0%{with tcmalloc} | |
434 | Requires: gperftools-libs >= 2.6.1 | |
435 | %endif | |
436 | %endif | |
9f95a23c | 437 | %if 0%{?weak_deps} |
11fdf7f2 | 438 | Recommends: chrony |
7c673cae | 439 | %endif |
7c673cae FG |
440 | %description base |
441 | Base is the package that includes all the files shared amongst ceph servers | |
442 | ||
9f95a23c TL |
443 | %package -n cephadm |
444 | Summary: Utility to bootstrap Ceph clusters | |
adb31ebb | 445 | BuildArch: noarch |
9f95a23c | 446 | Requires: lvm2 |
9f95a23c TL |
447 | Requires: python%{python3_pkgversion} |
448 | %if 0%{?weak_deps} | |
f67539c2 | 449 | Recommends: podman >= 2.0.2 |
9f95a23c TL |
450 | %endif |
451 | %description -n cephadm | |
452 | Utility to bootstrap a Ceph cluster and manage Ceph daemons deployed | |
453 | with systemd and podman. | |
454 | ||
7c673cae FG |
455 | %package -n ceph-common |
456 | Summary: Ceph Common | |
457 | %if 0%{?suse_version} | |
458 | Group: System/Filesystems | |
459 | %endif | |
31f18b77 FG |
460 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} |
461 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} | |
462 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} | |
9f95a23c TL |
463 | Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release} |
464 | Requires: python%{python3_pkgversion}-rbd = %{_epoch_prefix}%{version}-%{release} | |
465 | Requires: python%{python3_pkgversion}-cephfs = %{_epoch_prefix}%{version}-%{release} | |
466 | Requires: python%{python3_pkgversion}-rgw = %{_epoch_prefix}%{version}-%{release} | |
467 | Requires: python%{python3_pkgversion}-ceph-argparse = %{_epoch_prefix}%{version}-%{release} | |
468 | Requires: python%{python3_pkgversion}-ceph-common = %{_epoch_prefix}%{version}-%{release} | |
f67539c2 TL |
469 | %if 0%{with jaeger} |
470 | Requires: libjaeger = %{_epoch_prefix}%{version}-%{release} | |
471 | %endif | |
31f18b77 | 472 | %if 0%{?fedora} || 0%{?rhel} |
9f95a23c | 473 | Requires: python%{python3_pkgversion}-prettytable |
31f18b77 FG |
474 | %endif |
475 | %if 0%{?suse_version} | |
9f95a23c | 476 | Requires: python%{python3_pkgversion}-PrettyTable |
11fdf7f2 TL |
477 | %endif |
478 | %if 0%{with libradosstriper} | |
479 | Requires: libradosstriper1 = %{_epoch_prefix}%{version}-%{release} | |
31f18b77 | 480 | %endif |
7c673cae FG |
481 | %{?systemd_requires} |
482 | %if 0%{?suse_version} | |
483 | Requires(pre): pwdutils | |
484 | %endif | |
7c673cae FG |
485 | %description -n ceph-common |
486 | Common utilities to mount and interact with a ceph storage cluster. | |
487 | Comprised of files that are common to Ceph clients and servers. | |
488 | ||
489 | %package mds | |
490 | Summary: Ceph Metadata Server Daemon | |
491 | %if 0%{?suse_version} | |
492 | Group: System/Filesystems | |
493 | %endif | |
31f18b77 | 494 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
495 | %description mds |
496 | ceph-mds is the metadata server daemon for the Ceph distributed file system. | |
497 | One or more instances of ceph-mds collectively manage the file system | |
498 | namespace, coordinating access to the shared OSD cluster. | |
499 | ||
500 | %package mon | |
501 | Summary: Ceph Monitor Daemon | |
502 | %if 0%{?suse_version} | |
503 | Group: System/Filesystems | |
504 | %endif | |
11fdf7f2 | 505 | Provides: ceph-test:/usr/bin/ceph-monstore-tool |
31f18b77 | 506 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
f91f0fd5 TL |
507 | %if 0%{?weak_deps} |
508 | Recommends: nvme-cli | |
adb31ebb TL |
509 | %if 0%{?suse_version} |
510 | Requires: smartmontools | |
511 | %else | |
f91f0fd5 TL |
512 | Recommends: smartmontools |
513 | %endif | |
adb31ebb | 514 | %endif |
f67539c2 TL |
515 | %if 0%{with jaeger} |
516 | Requires: libjaeger = %{_epoch_prefix}%{version}-%{release} | |
517 | %endif | |
7c673cae FG |
518 | %description mon |
519 | ceph-mon is the cluster monitor daemon for the Ceph distributed file | |
520 | system. One or more instances of ceph-mon form a Paxos part-time | |
521 | parliament cluster that provides extremely reliable and durable storage | |
522 | of cluster membership, configuration, and state. | |
523 | ||
524 | %package mgr | |
525 | Summary: Ceph Manager Daemon | |
7c673cae FG |
526 | %if 0%{?suse_version} |
527 | Group: System/Filesystems | |
528 | %endif | |
31f18b77 | 529 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
9f95a23c | 530 | Requires: ceph-mgr-modules-core = %{_epoch_prefix}%{version}-%{release} |
f67539c2 | 531 | Requires: libcephsqlite = %{_epoch_prefix}%{version}-%{release} |
9f95a23c | 532 | %if 0%{?weak_deps} |
11fdf7f2 TL |
533 | Recommends: ceph-mgr-dashboard = %{_epoch_prefix}%{version}-%{release} |
534 | Recommends: ceph-mgr-diskprediction-local = %{_epoch_prefix}%{version}-%{release} | |
eafe8130 | 535 | Recommends: ceph-mgr-k8sevents = %{_epoch_prefix}%{version}-%{release} |
9f95a23c TL |
536 | Recommends: ceph-mgr-cephadm = %{_epoch_prefix}%{version}-%{release} |
537 | Recommends: python%{python3_pkgversion}-influxdb | |
31f18b77 | 538 | %endif |
7c673cae FG |
539 | %description mgr |
540 | ceph-mgr enables python modules that provide services (such as the REST | |
541 | module derived from Calamari) and expose CLI hooks. ceph-mgr gathers | |
542 | the cluster maps, the daemon metadata, and performance counters, and | |
543 | exposes all these to the python modules. | |
544 | ||
11fdf7f2 TL |
545 | %package mgr-dashboard |
546 | Summary: Ceph Dashboard | |
547 | BuildArch: noarch | |
548 | %if 0%{?suse_version} | |
549 | Group: System/Filesystems | |
550 | %endif | |
551 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
494da23a | 552 | Requires: ceph-grafana-dashboards = %{_epoch_prefix}%{version}-%{release} |
801d1391 | 553 | Requires: ceph-prometheus-alerts = %{_epoch_prefix}%{version}-%{release} |
11fdf7f2 | 554 | %if 0%{?fedora} || 0%{?rhel} |
9f95a23c TL |
555 | Requires: python%{python3_pkgversion}-cherrypy |
556 | Requires: python%{python3_pkgversion}-jwt | |
557 | Requires: python%{python3_pkgversion}-routes | |
558 | Requires: python%{python3_pkgversion}-werkzeug | |
1911f103 TL |
559 | %if 0%{?weak_deps} |
560 | Recommends: python%{python3_pkgversion}-saml | |
561 | %endif | |
11fdf7f2 TL |
562 | %endif |
563 | %if 0%{?suse_version} | |
9f95a23c TL |
564 | Requires: python%{python3_pkgversion}-CherryPy |
565 | Requires: python%{python3_pkgversion}-PyJWT | |
566 | Requires: python%{python3_pkgversion}-Routes | |
567 | Requires: python%{python3_pkgversion}-Werkzeug | |
1911f103 | 568 | Recommends: python%{python3_pkgversion}-python3-saml |
11fdf7f2 TL |
569 | %endif |
570 | %description mgr-dashboard | |
9f95a23c | 571 | ceph-mgr-dashboard is a manager module, providing a web-based application |
11fdf7f2 TL |
572 | to monitor and manage many aspects of a Ceph cluster and related components. |
573 | See the Dashboard documentation at http://docs.ceph.com/ for details and a | |
574 | detailed feature overview. | |
575 | ||
576 | %package mgr-diskprediction-local | |
9f95a23c | 577 | Summary: Ceph Manager module for predicting disk failures |
11fdf7f2 TL |
578 | BuildArch: noarch |
579 | %if 0%{?suse_version} | |
580 | Group: System/Filesystems | |
581 | %endif | |
582 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
9f95a23c | 583 | Requires: python%{python3_pkgversion}-numpy |
f67539c2 TL |
584 | %if 0%{?fedora} || 0%{?suse_version} |
585 | Requires: python%{python3_pkgversion}-scikit-learn | |
11fdf7f2 | 586 | %endif |
f67539c2 | 587 | Requires: python3-scipy |
11fdf7f2 | 588 | %description mgr-diskprediction-local |
9f95a23c | 589 | ceph-mgr-diskprediction-local is a ceph-mgr module that tries to predict |
11fdf7f2 TL |
590 | disk failures using local algorithms and machine-learning databases. |
591 | ||
9f95a23c TL |
592 | %package mgr-modules-core |
593 | Summary: Ceph Manager modules which are always enabled | |
594 | BuildArch: noarch | |
595 | %if 0%{?suse_version} | |
596 | Group: System/Filesystems | |
597 | %endif | |
9f95a23c TL |
598 | Requires: python%{python3_pkgversion}-bcrypt |
599 | Requires: python%{python3_pkgversion}-pecan | |
600 | Requires: python%{python3_pkgversion}-pyOpenSSL | |
601 | Requires: python%{python3_pkgversion}-requests | |
602 | Requires: python%{python3_pkgversion}-dateutil | |
9f95a23c TL |
603 | %if 0%{?fedora} || 0%{?rhel} >= 8 |
604 | Requires: python%{python3_pkgversion}-cherrypy | |
605 | Requires: python%{python3_pkgversion}-pyyaml | |
606 | Requires: python%{python3_pkgversion}-werkzeug | |
607 | %endif | |
608 | %if 0%{?suse_version} | |
609 | Requires: python%{python3_pkgversion}-CherryPy | |
610 | Requires: python%{python3_pkgversion}-PyYAML | |
611 | Requires: python%{python3_pkgversion}-Werkzeug | |
612 | %endif | |
613 | %if 0%{?weak_deps} | |
614 | Recommends: ceph-mgr-rook = %{_epoch_prefix}%{version}-%{release} | |
615 | %endif | |
616 | %description mgr-modules-core | |
617 | ceph-mgr-modules-core provides a set of modules which are always | |
618 | enabled by ceph-mgr. | |
619 | ||
11fdf7f2 TL |
620 | %package mgr-rook |
621 | BuildArch: noarch | |
9f95a23c | 622 | Summary: Ceph Manager module for Rook-based orchestration |
11fdf7f2 TL |
623 | %if 0%{?suse_version} |
624 | Group: System/Filesystems | |
625 | %endif | |
626 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
9f95a23c TL |
627 | Requires: python%{python3_pkgversion}-kubernetes |
628 | Requires: python%{python3_pkgversion}-jsonpatch | |
11fdf7f2 | 629 | %description mgr-rook |
9f95a23c | 630 | ceph-mgr-rook is a ceph-mgr module for orchestration functions using |
11fdf7f2 TL |
631 | a Rook backend. |
632 | ||
eafe8130 TL |
633 | %package mgr-k8sevents |
634 | BuildArch: noarch | |
9f95a23c | 635 | Summary: Ceph Manager module to orchestrate ceph-events to kubernetes' events API |
eafe8130 TL |
636 | %if 0%{?suse_version} |
637 | Group: System/Filesystems | |
638 | %endif | |
639 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
9f95a23c | 640 | Requires: python%{python3_pkgversion}-kubernetes |
eafe8130 | 641 | %description mgr-k8sevents |
9f95a23c | 642 | ceph-mgr-k8sevents is a ceph-mgr module that sends every ceph-events |
eafe8130 TL |
643 | to kubernetes' events API |
644 | ||
9f95a23c TL |
645 | %package mgr-cephadm |
646 | Summary: Ceph Manager module for cephadm-based orchestration | |
11fdf7f2 TL |
647 | BuildArch: noarch |
648 | %if 0%{?suse_version} | |
649 | Group: System/Filesystems | |
650 | %endif | |
651 | Requires: ceph-mgr = %{_epoch_prefix}%{version}-%{release} | |
9f95a23c TL |
652 | Requires: python%{python3_pkgversion}-remoto |
653 | Requires: cephadm = %{_epoch_prefix}%{version}-%{release} | |
654 | %if 0%{?suse_version} | |
655 | Requires: openssh | |
e306af50 | 656 | Requires: python%{python3_pkgversion}-Jinja2 |
9f95a23c TL |
657 | %endif |
658 | %if 0%{?rhel} || 0%{?fedora} | |
659 | Requires: openssh-clients | |
e306af50 | 660 | Requires: python%{python3_pkgversion}-jinja2 |
9f95a23c TL |
661 | %endif |
662 | %description mgr-cephadm | |
663 | ceph-mgr-cephadm is a ceph-mgr module for orchestration functions using | |
664 | the integrated cephadm deployment tool management operations. | |
11fdf7f2 | 665 | |
7c673cae FG |
666 | %package fuse |
667 | Summary: Ceph fuse-based client | |
668 | %if 0%{?suse_version} | |
669 | Group: System/Filesystems | |
670 | %endif | |
181888fb | 671 | Requires: fuse |
11fdf7f2 | 672 | Requires: python%{python3_pkgversion} |
7c673cae FG |
673 | %description fuse |
674 | FUSE based client for Ceph distributed network file system | |
675 | ||
f67539c2 TL |
676 | %package -n cephfs-mirror |
677 | Summary: Ceph daemon for mirroring CephFS snapshots | |
678 | %if 0%{?suse_version} | |
679 | Group: System/Filesystems | |
680 | %endif | |
681 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} | |
682 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} | |
683 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} | |
684 | %description -n cephfs-mirror | |
685 | Daemon for mirroring CephFS snapshots between Ceph clusters. | |
686 | ||
7c673cae FG |
687 | %package -n rbd-fuse |
688 | Summary: Ceph fuse-based client | |
689 | %if 0%{?suse_version} | |
690 | Group: System/Filesystems | |
691 | %endif | |
31f18b77 FG |
692 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
693 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
694 | %description -n rbd-fuse |
695 | FUSE based client to map Ceph rbd images to files | |
696 | ||
697 | %package -n rbd-mirror | |
698 | Summary: Ceph daemon for mirroring RBD images | |
699 | %if 0%{?suse_version} | |
700 | Group: System/Filesystems | |
701 | %endif | |
a8e16298 | 702 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
31f18b77 | 703 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
11fdf7f2 | 704 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
705 | %description -n rbd-mirror |
706 | Daemon for mirroring RBD images between Ceph clusters, streaming | |
707 | changes asynchronously. | |
708 | ||
9f95a23c TL |
709 | %package immutable-object-cache |
710 | Summary: Ceph daemon for immutable object cache | |
711 | %if 0%{?suse_version} | |
712 | Group: System/Filesystems | |
713 | %endif | |
f67539c2 | 714 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
9f95a23c TL |
715 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
716 | %description immutable-object-cache | |
717 | Daemon for immutable object cache. | |
718 | ||
7c673cae FG |
719 | %package -n rbd-nbd |
720 | Summary: Ceph RBD client base on NBD | |
721 | %if 0%{?suse_version} | |
722 | Group: System/Filesystems | |
723 | %endif | |
31f18b77 FG |
724 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
725 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
726 | %description -n rbd-nbd |
727 | NBD based client to map Ceph rbd images to local device | |
728 | ||
729 | %package radosgw | |
730 | Summary: Rados REST gateway | |
731 | %if 0%{?suse_version} | |
732 | Group: System/Filesystems | |
733 | %endif | |
a8e16298 | 734 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
7c673cae | 735 | %if 0%{with selinux} |
31f18b77 | 736 | Requires: ceph-selinux = %{_epoch_prefix}%{version}-%{release} |
7c673cae | 737 | %endif |
31f18b77 FG |
738 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
739 | Requires: librgw2 = %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
740 | %if 0%{?rhel} || 0%{?fedora} |
741 | Requires: mailcap | |
742 | %endif | |
f67539c2 TL |
743 | %if 0%{?weak_deps} |
744 | Recommends: gawk | |
745 | %endif | |
7c673cae FG |
746 | %description radosgw |
747 | RADOS is a distributed object store used by the Ceph distributed | |
748 | storage system. This package provides a REST gateway to the | |
749 | object store that aims to implement a superset of Amazon's S3 | |
750 | service as well as the OpenStack Object Storage ("Swift") API. | |
751 | ||
f67539c2 TL |
752 | %package -n cephfs-top |
753 | Summary: top(1) like utility for Ceph Filesystem | |
754 | BuildArch: noarch | |
755 | Requires: python%{python3_pkgversion}-rados | |
756 | %description -n cephfs-top | |
757 | This package provides a top(1) like utility to display Ceph Filesystem metrics | |
758 | in realtime. | |
759 | ||
7c673cae FG |
760 | %if %{with ocf} |
761 | %package resource-agents | |
762 | Summary: OCF-compliant resource agents for Ceph daemons | |
763 | %if 0%{?suse_version} | |
764 | Group: System/Filesystems | |
765 | %endif | |
31f18b77 | 766 | Requires: ceph-base = %{_epoch_prefix}%{version} |
7c673cae FG |
767 | Requires: resource-agents |
768 | %description resource-agents | |
769 | Resource agents for monitoring and managing Ceph daemons | |
770 | under Open Cluster Framework (OCF) compliant resource | |
771 | managers such as Pacemaker. | |
772 | %endif | |
773 | ||
774 | %package osd | |
775 | Summary: Ceph Object Storage Daemon | |
776 | %if 0%{?suse_version} | |
777 | Group: System/Filesystems | |
778 | %endif | |
11fdf7f2 | 779 | Provides: ceph-test:/usr/bin/ceph-osdomap-tool |
31f18b77 | 780 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
b32b8144 | 781 | Requires: lvm2 |
11fdf7f2 | 782 | Requires: sudo |
9f95a23c | 783 | Requires: libstoragemgmt |
f6b5b4d7 | 784 | Requires: python%{python3_pkgversion}-ceph-common = %{_epoch_prefix}%{version}-%{release} |
f91f0fd5 TL |
785 | %if 0%{?weak_deps} |
786 | Recommends: nvme-cli | |
adb31ebb TL |
787 | %if 0%{?suse_version} |
788 | Requires: smartmontools | |
789 | %else | |
f91f0fd5 TL |
790 | Recommends: smartmontools |
791 | %endif | |
adb31ebb | 792 | %endif |
7c673cae FG |
793 | %description osd |
794 | ceph-osd is the object storage daemon for the Ceph distributed file | |
795 | system. It is responsible for storing objects on a local file system | |
796 | and providing access to them over the network. | |
797 | ||
9f95a23c TL |
798 | %if 0%{with seastar} |
799 | %package crimson-osd | |
800 | Summary: Ceph Object Storage Daemon (crimson) | |
801 | %if 0%{?suse_version} | |
802 | Group: System/Filesystems | |
803 | %endif | |
804 | Requires: ceph-osd = %{_epoch_prefix}%{version}-%{release} | |
805 | %description crimson-osd | |
806 | crimson-osd is the object storage daemon for the Ceph distributed file | |
807 | system. It is responsible for storing objects on a local file system | |
808 | and providing access to them over the network. | |
809 | %endif | |
810 | ||
7c673cae FG |
811 | %package -n librados2 |
812 | Summary: RADOS distributed object store client library | |
813 | %if 0%{?suse_version} | |
814 | Group: System/Libraries | |
815 | %endif | |
7c673cae | 816 | %if 0%{?rhel} || 0%{?fedora} |
31f18b77 | 817 | Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
818 | %endif |
819 | %description -n librados2 | |
820 | RADOS is a reliable, autonomic distributed object storage cluster | |
821 | developed as part of the Ceph distributed storage system. This is a | |
822 | shared library allowing applications to access the distributed object | |
823 | store using a simple file-like interface. | |
824 | ||
825 | %package -n librados-devel | |
826 | Summary: RADOS headers | |
827 | %if 0%{?suse_version} | |
828 | Group: Development/Libraries/C and C++ | |
829 | %endif | |
31f18b77 FG |
830 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
831 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} | |
832 | Provides: librados2-devel = %{_epoch_prefix}%{version}-%{release} | |
833 | Obsoletes: librados2-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae | 834 | %description -n librados-devel |
11fdf7f2 TL |
835 | This package contains C libraries and headers needed to develop programs |
836 | that use RADOS object store. | |
837 | ||
838 | %package -n libradospp-devel | |
839 | Summary: RADOS headers | |
840 | %if 0%{?suse_version} | |
841 | Group: Development/Libraries/C and C++ | |
842 | %endif | |
843 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} | |
844 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} | |
845 | %description -n libradospp-devel | |
846 | This package contains C++ libraries and headers needed to develop programs | |
7c673cae FG |
847 | that use RADOS object store. |
848 | ||
849 | %package -n librgw2 | |
850 | Summary: RADOS gateway client library | |
851 | %if 0%{?suse_version} | |
852 | Group: System/Libraries | |
853 | %endif | |
31f18b77 | 854 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
855 | %description -n librgw2 |
856 | This package provides a library implementation of the RADOS gateway | |
857 | (distributed object store with S3 and Swift personalities). | |
858 | ||
859 | %package -n librgw-devel | |
860 | Summary: RADOS gateway client library | |
861 | %if 0%{?suse_version} | |
862 | Group: Development/Libraries/C and C++ | |
863 | %endif | |
31f18b77 FG |
864 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} |
865 | Requires: librgw2 = %{_epoch_prefix}%{version}-%{release} | |
866 | Provides: librgw2-devel = %{_epoch_prefix}%{version}-%{release} | |
867 | Obsoletes: librgw2-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
868 | %description -n librgw-devel |
869 | This package contains libraries and headers needed to develop programs | |
870 | that use RADOS gateway client library. | |
871 | ||
7c673cae FG |
872 | %package -n python%{python3_pkgversion}-rgw |
873 | Summary: Python 3 libraries for the RADOS gateway | |
874 | %if 0%{?suse_version} | |
11fdf7f2 | 875 | Group: Development/Libraries/Python |
7c673cae | 876 | %endif |
31f18b77 FG |
877 | Requires: librgw2 = %{_epoch_prefix}%{version}-%{release} |
878 | Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release} | |
eafe8130 | 879 | %{?python_provide:%python_provide python%{python3_pkgversion}-rgw} |
81eedcae TL |
880 | Provides: python-rgw = %{_epoch_prefix}%{version}-%{release} |
881 | Obsoletes: python-rgw < %{_epoch_prefix}%{version}-%{release} | |
7c673cae | 882 | %description -n python%{python3_pkgversion}-rgw |
f67539c2 | 883 | This package contains Python 3 libraries for interacting with Ceph RADOS |
7c673cae FG |
884 | gateway. |
885 | ||
7c673cae FG |
886 | %package -n python%{python3_pkgversion}-rados |
887 | Summary: Python 3 libraries for the RADOS object store | |
888 | %if 0%{?suse_version} | |
11fdf7f2 | 889 | Group: Development/Libraries/Python |
7c673cae | 890 | %endif |
7c673cae | 891 | Requires: python%{python3_pkgversion} |
31f18b77 | 892 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
eafe8130 | 893 | %{?python_provide:%python_provide python%{python3_pkgversion}-rados} |
81eedcae | 894 | Provides: python-rados = %{_epoch_prefix}%{version}-%{release} |
9f95a23c | 895 | Obsoletes: python-rados < %{_epoch_prefix}%{version}-%{release} |
7c673cae | 896 | %description -n python%{python3_pkgversion}-rados |
f67539c2 | 897 | This package contains Python 3 libraries for interacting with Ceph RADOS |
7c673cae FG |
898 | object store. |
899 | ||
f67539c2 TL |
900 | %package -n libcephsqlite |
901 | Summary: SQLite3 VFS for Ceph | |
902 | %if 0%{?suse_version} | |
903 | Group: System/Libraries | |
904 | %endif | |
905 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} | |
906 | %description -n libcephsqlite | |
907 | A SQLite3 VFS for storing and manipulating databases stored on Ceph's RADOS | |
908 | distributed object store. | |
909 | ||
910 | %package -n libcephsqlite-devel | |
911 | Summary: SQLite3 VFS for Ceph headers | |
912 | %if 0%{?suse_version} | |
913 | Group: Development/Libraries/C and C++ | |
914 | %endif | |
915 | Requires: sqlite-devel | |
916 | Requires: libcephsqlite = %{_epoch_prefix}%{version}-%{release} | |
917 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} | |
918 | Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release} | |
919 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} | |
920 | Provides: libcephsqlite-devel = %{_epoch_prefix}%{version}-%{release} | |
921 | Obsoletes: libcephsqlite-devel < %{_epoch_prefix}%{version}-%{release} | |
922 | %description -n libcephsqlite-devel | |
923 | A SQLite3 VFS for storing and manipulating databases stored on Ceph's RADOS | |
924 | distributed object store. | |
925 | ||
11fdf7f2 | 926 | %if 0%{with libradosstriper} |
7c673cae FG |
927 | %package -n libradosstriper1 |
928 | Summary: RADOS striping interface | |
929 | %if 0%{?suse_version} | |
930 | Group: System/Libraries | |
931 | %endif | |
31f18b77 | 932 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
933 | %description -n libradosstriper1 |
934 | Striping interface built on top of the rados library, allowing | |
935 | to stripe bigger objects onto several standard rados objects using | |
936 | an interface very similar to the rados one. | |
937 | ||
938 | %package -n libradosstriper-devel | |
939 | Summary: RADOS striping interface headers | |
940 | %if 0%{?suse_version} | |
941 | Group: Development/Libraries/C and C++ | |
942 | %endif | |
31f18b77 FG |
943 | Requires: libradosstriper1 = %{_epoch_prefix}%{version}-%{release} |
944 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} | |
11fdf7f2 | 945 | Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release} |
31f18b77 FG |
946 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} |
947 | Provides: libradosstriper1-devel = %{_epoch_prefix}%{version}-%{release} | |
948 | Obsoletes: libradosstriper1-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
949 | %description -n libradosstriper-devel |
950 | This package contains libraries and headers needed to develop programs | |
951 | that use RADOS striping interface. | |
11fdf7f2 | 952 | %endif |
7c673cae FG |
953 | |
954 | %package -n librbd1 | |
955 | Summary: RADOS block device client library | |
956 | %if 0%{?suse_version} | |
957 | Group: System/Libraries | |
958 | %endif | |
31f18b77 FG |
959 | Requires: librados2 = %{_epoch_prefix}%{version}-%{release} |
960 | %if 0%{?suse_version} | |
961 | Requires(post): coreutils | |
962 | %endif | |
7c673cae | 963 | %if 0%{?rhel} || 0%{?fedora} |
31f18b77 | 964 | Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
965 | %endif |
966 | %description -n librbd1 | |
967 | RBD is a block device striped across multiple distributed objects in | |
968 | RADOS, a reliable, autonomic distributed object storage cluster | |
969 | developed as part of the Ceph distributed storage system. This is a | |
970 | shared library allowing applications to manage these block devices. | |
971 | ||
972 | %package -n librbd-devel | |
973 | Summary: RADOS block device headers | |
974 | %if 0%{?suse_version} | |
975 | Group: Development/Libraries/C and C++ | |
976 | %endif | |
31f18b77 FG |
977 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} |
978 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} | |
11fdf7f2 | 979 | Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release} |
31f18b77 FG |
980 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} |
981 | Provides: librbd1-devel = %{_epoch_prefix}%{version}-%{release} | |
982 | Obsoletes: librbd1-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
983 | %description -n librbd-devel |
984 | This package contains libraries and headers needed to develop programs | |
985 | that use RADOS block device. | |
986 | ||
7c673cae FG |
987 | %package -n python%{python3_pkgversion}-rbd |
988 | Summary: Python 3 libraries for the RADOS block device | |
989 | %if 0%{?suse_version} | |
11fdf7f2 | 990 | Group: Development/Libraries/Python |
7c673cae | 991 | %endif |
31f18b77 FG |
992 | Requires: librbd1 = %{_epoch_prefix}%{version}-%{release} |
993 | Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release} | |
eafe8130 | 994 | %{?python_provide:%python_provide python%{python3_pkgversion}-rbd} |
81eedcae TL |
995 | Provides: python-rbd = %{_epoch_prefix}%{version}-%{release} |
996 | Obsoletes: python-rbd < %{_epoch_prefix}%{version}-%{release} | |
7c673cae | 997 | %description -n python%{python3_pkgversion}-rbd |
f67539c2 | 998 | This package contains Python 3 libraries for interacting with Ceph RADOS |
7c673cae FG |
999 | block device. |
1000 | ||
1001 | %package -n libcephfs2 | |
1002 | Summary: Ceph distributed file system client library | |
1003 | %if 0%{?suse_version} | |
1004 | Group: System/Libraries | |
1005 | %endif | |
1911f103 | 1006 | Obsoletes: libcephfs1 < %{_epoch_prefix}%{version}-%{release} |
7c673cae | 1007 | %if 0%{?rhel} || 0%{?fedora} |
31f18b77 | 1008 | Obsoletes: ceph-libs < %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
1009 | Obsoletes: ceph-libcephfs |
1010 | %endif | |
1011 | %description -n libcephfs2 | |
1012 | Ceph is a distributed network file system designed to provide excellent | |
1013 | performance, reliability, and scalability. This is a shared library | |
1014 | allowing applications to access a Ceph distributed file system via a | |
1015 | POSIX-like interface. | |
1016 | ||
1017 | %package -n libcephfs-devel | |
1018 | Summary: Ceph distributed file system headers | |
1019 | %if 0%{?suse_version} | |
1020 | Group: Development/Libraries/C and C++ | |
1021 | %endif | |
31f18b77 FG |
1022 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} |
1023 | Requires: librados-devel = %{_epoch_prefix}%{version}-%{release} | |
1024 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} | |
1025 | Provides: libcephfs2-devel = %{_epoch_prefix}%{version}-%{release} | |
1026 | Obsoletes: libcephfs2-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
1027 | %description -n libcephfs-devel |
1028 | This package contains libraries and headers needed to develop programs | |
f67539c2 TL |
1029 | that use Ceph distributed file system. |
1030 | ||
1031 | %if 0%{with jaeger} | |
1032 | %package -n libjaeger | |
1033 | Summary: Ceph distributed file system tracing library | |
1034 | %if 0%{?suse_version} | |
1035 | Group: System/Libraries | |
1036 | %endif | |
1037 | Provides: libjaegertracing.so.0()(64bit) | |
1038 | Provides: libopentracing.so.1()(64bit) | |
1039 | Provides: libthrift.so.0.13.0()(64bit) | |
1040 | %description -n libjaeger | |
1041 | This package contains libraries needed to provide distributed | |
1042 | tracing for Ceph. | |
1043 | %endif | |
7c673cae | 1044 | |
7c673cae FG |
1045 | %package -n python%{python3_pkgversion}-cephfs |
1046 | Summary: Python 3 libraries for Ceph distributed file system | |
1047 | %if 0%{?suse_version} | |
11fdf7f2 | 1048 | Group: Development/Libraries/Python |
7c673cae | 1049 | %endif |
31f18b77 FG |
1050 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} |
1051 | Requires: python%{python3_pkgversion}-rados = %{_epoch_prefix}%{version}-%{release} | |
11fdf7f2 | 1052 | Requires: python%{python3_pkgversion}-ceph-argparse = %{_epoch_prefix}%{version}-%{release} |
eafe8130 | 1053 | %{?python_provide:%python_provide python%{python3_pkgversion}-cephfs} |
81eedcae TL |
1054 | Provides: python-cephfs = %{_epoch_prefix}%{version}-%{release} |
1055 | Obsoletes: python-cephfs < %{_epoch_prefix}%{version}-%{release} | |
7c673cae | 1056 | %description -n python%{python3_pkgversion}-cephfs |
f67539c2 | 1057 | This package contains Python 3 libraries for interacting with Ceph distributed |
7c673cae FG |
1058 | file system. |
1059 | ||
1060 | %package -n python%{python3_pkgversion}-ceph-argparse | |
1061 | Summary: Python 3 utility libraries for Ceph CLI | |
1062 | %if 0%{?suse_version} | |
11fdf7f2 | 1063 | Group: Development/Libraries/Python |
7c673cae | 1064 | %endif |
eafe8130 | 1065 | %{?python_provide:%python_provide python%{python3_pkgversion}-ceph-argparse} |
7c673cae FG |
1066 | %description -n python%{python3_pkgversion}-ceph-argparse |
1067 | This package contains types and routines for Python 3 used by the Ceph CLI as | |
1068 | well as the RESTful interface. These have to do with querying the daemons for | |
1069 | command-description information, validating user command input against those | |
1070 | descriptions, and submitting the command to the appropriate daemon. | |
1071 | ||
9f95a23c TL |
1072 | %package -n python%{python3_pkgversion}-ceph-common |
1073 | Summary: Python 3 utility libraries for Ceph | |
f6b5b4d7 TL |
1074 | %if 0%{?fedora} || 0%{?rhel} >= 8 |
1075 | Requires: python%{python3_pkgversion}-pyyaml | |
1076 | %endif | |
1077 | %if 0%{?suse_version} | |
1078 | Requires: python%{python3_pkgversion}-PyYAML | |
1079 | %endif | |
9f95a23c TL |
1080 | %if 0%{?suse_version} |
1081 | Group: Development/Libraries/Python | |
1082 | %endif | |
1083 | %{?python_provide:%python_provide python%{python3_pkgversion}-ceph-common} | |
1084 | %description -n python%{python3_pkgversion}-ceph-common | |
1085 | This package contains data structures, classes and functions used by Ceph. | |
1086 | It also contains utilities used for the cephadm orchestrator. | |
1087 | ||
11fdf7f2 TL |
1088 | %if 0%{with cephfs_shell} |
1089 | %package -n cephfs-shell | |
1090 | Summary: Interactive shell for Ceph file system | |
1091 | Requires: python%{python3_pkgversion}-cmd2 | |
1092 | Requires: python%{python3_pkgversion}-colorama | |
1093 | Requires: python%{python3_pkgversion}-cephfs | |
1094 | %description -n cephfs-shell | |
1095 | This package contains an interactive tool that allows accessing a Ceph | |
1096 | file system without mounting it by providing a nice pseudo-shell which | |
1097 | works like an FTP client. | |
1098 | %endif | |
1099 | ||
7c673cae FG |
1100 | %if 0%{with ceph_test_package} |
1101 | %package -n ceph-test | |
1102 | Summary: Ceph benchmarks and test tools | |
1103 | %if 0%{?suse_version} | |
1104 | Group: System/Benchmark | |
1105 | %endif | |
b32b8144 | 1106 | Requires: ceph-common = %{_epoch_prefix}%{version}-%{release} |
7c673cae | 1107 | Requires: xmlstarlet |
31f18b77 | 1108 | Requires: jq |
c07f9fc5 | 1109 | Requires: socat |
7c673cae FG |
1110 | %description -n ceph-test |
1111 | This package contains Ceph benchmarks and test tools. | |
1112 | %endif | |
1113 | ||
1114 | %if 0%{with cephfs_java} | |
1115 | ||
1116 | %package -n libcephfs_jni1 | |
1117 | Summary: Java Native Interface library for CephFS Java bindings | |
1118 | %if 0%{?suse_version} | |
1119 | Group: System/Libraries | |
1120 | %endif | |
7c673cae | 1121 | Requires: java |
31f18b77 | 1122 | Requires: libcephfs2 = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
1123 | %description -n libcephfs_jni1 |
1124 | This package contains the Java Native Interface library for CephFS Java | |
1125 | bindings. | |
1126 | ||
1127 | %package -n libcephfs_jni-devel | |
1128 | Summary: Development files for CephFS Java Native Interface library | |
1129 | %if 0%{?suse_version} | |
1130 | Group: Development/Libraries/Java | |
1131 | %endif | |
7c673cae | 1132 | Requires: java |
31f18b77 FG |
1133 | Requires: libcephfs_jni1 = %{_epoch_prefix}%{version}-%{release} |
1134 | Obsoletes: ceph-devel < %{_epoch_prefix}%{version}-%{release} | |
1135 | Provides: libcephfs_jni1-devel = %{_epoch_prefix}%{version}-%{release} | |
1136 | Obsoletes: libcephfs_jni1-devel < %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
1137 | %description -n libcephfs_jni-devel |
1138 | This package contains the development files for CephFS Java Native Interface | |
1139 | library. | |
1140 | ||
1141 | %package -n cephfs-java | |
1142 | Summary: Java libraries for the Ceph File System | |
1143 | %if 0%{?suse_version} | |
1144 | Group: System/Libraries | |
1145 | %endif | |
7c673cae | 1146 | Requires: java |
31f18b77 | 1147 | Requires: libcephfs_jni1 = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
1148 | Requires: junit |
1149 | BuildRequires: junit | |
1150 | %description -n cephfs-java | |
1151 | This package contains the Java libraries for the Ceph File System. | |
1152 | ||
1153 | %endif | |
1154 | ||
1155 | %package -n rados-objclass-devel | |
1156 | Summary: RADOS object class development kit | |
11fdf7f2 TL |
1157 | %if 0%{?suse_version} |
1158 | Group: Development/Libraries/C and C++ | |
1159 | %endif | |
1160 | Requires: libradospp-devel = %{_epoch_prefix}%{version}-%{release} | |
7c673cae FG |
1161 | %description -n rados-objclass-devel |
1162 | This package contains libraries and headers needed to develop RADOS object | |
1163 | class plugins. | |
1164 | ||
1165 | %if 0%{with selinux} | |
1166 | ||
1167 | %package selinux | |
1168 | Summary: SELinux support for Ceph MON, OSD and MDS | |
1169 | %if 0%{?suse_version} | |
1170 | Group: System/Filesystems | |
1171 | %endif | |
31f18b77 | 1172 | Requires: ceph-base = %{_epoch_prefix}%{version}-%{release} |
7c673cae | 1173 | Requires: policycoreutils, libselinux-utils |
31f18b77 | 1174 | Requires(post): ceph-base = %{_epoch_prefix}%{version}-%{release} |
7c673cae FG |
1175 | Requires(post): selinux-policy-base >= %{_selinux_policy_version}, policycoreutils, gawk |
1176 | Requires(postun): policycoreutils | |
1177 | %description selinux | |
1178 | This package contains SELinux support for Ceph MON, OSD and MDS. The package | |
1179 | also performs file-system relabelling which can take a long time on heavily | |
1180 | populated file-systems. | |
1181 | ||
1182 | %endif | |
1183 | ||
11fdf7f2 TL |
1184 | %package grafana-dashboards |
1185 | Summary: The set of Grafana dashboards for monitoring purposes | |
1186 | BuildArch: noarch | |
1187 | %if 0%{?suse_version} | |
1188 | Group: System/Filesystems | |
1189 | %endif | |
1190 | %description grafana-dashboards | |
1191 | This package provides a set of Grafana dashboards for monitoring of | |
1192 | Ceph clusters. The dashboards require a Prometheus server setup | |
1193 | collecting data from Ceph Manager "prometheus" module and Prometheus | |
1194 | project "node_exporter" module. The dashboards are designed to be | |
1195 | integrated with the Ceph Manager Dashboard web UI. | |
7c673cae | 1196 | |
81eedcae | 1197 | %package prometheus-alerts |
f67539c2 | 1198 | Summary: Prometheus alerts for a Ceph deployment |
81eedcae TL |
1199 | BuildArch: noarch |
1200 | Group: System/Monitoring | |
1201 | %description prometheus-alerts | |
f67539c2 | 1202 | This package provides Ceph default alerts for Prometheus. |
81eedcae | 1203 | |
7c673cae FG |
1204 | ################################################################################# |
1205 | # common | |
1206 | ################################################################################# | |
1207 | %prep | |
18d92ca7 | 1208 | %autosetup -p1 -n ceph-16.2.4 |
7c673cae FG |
1209 | |
1210 | %build | |
81eedcae TL |
1211 | # LTO can be enabled as soon as the following GCC bug is fixed: |
1212 | # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48200 | |
1213 | %define _lto_cflags %{nil} | |
11fdf7f2 | 1214 | |
f67539c2 TL |
1215 | %if 0%{with seastar} && 0%{?rhel} |
1216 | . /opt/rh/gcc-toolset-9/enable | |
11fdf7f2 TL |
1217 | %endif |
1218 | ||
7c673cae FG |
1219 | %if 0%{with cephfs_java} |
1220 | # Find jni.h | |
1221 | for i in /usr/{lib64,lib}/jvm/java/include{,/linux}; do | |
1222 | [ -d $i ] && java_inc="$java_inc -I$i" | |
1223 | done | |
1224 | %endif | |
1225 | ||
11fdf7f2 TL |
1226 | %if 0%{?suse_version} |
1227 | # the following setting fixed an OOM condition we once encountered in the OBS | |
7c673cae FG |
1228 | RPM_OPT_FLAGS="$RPM_OPT_FLAGS --param ggc-min-expand=20 --param ggc-min-heapsize=32768" |
1229 | %endif | |
7c673cae FG |
1230 | |
1231 | export CPPFLAGS="$java_inc" | |
1232 | export CFLAGS="$RPM_OPT_FLAGS" | |
1233 | export CXXFLAGS="$RPM_OPT_FLAGS" | |
f64942e4 | 1234 | export LDFLAGS="$RPM_LD_FLAGS" |
7c673cae | 1235 | |
f67539c2 TL |
1236 | %if 0%{with seastar} |
1237 | # seastar uses longjmp() to implement coroutine. and this annoys longjmp_chk() | |
1238 | export CXXFLAGS=$(echo $RPM_OPT_FLAGS | sed -e 's/-Wp,-D_FORTIFY_SOURCE=2//g') | |
1239 | %endif | |
1240 | ||
11fdf7f2 TL |
1241 | # Parallel build settings ... |
1242 | CEPH_MFLAGS_JOBS="%{?_smp_mflags}" | |
1243 | CEPH_SMP_NCPUS=$(echo "$CEPH_MFLAGS_JOBS" | sed 's/-j//') | |
1244 | %if 0%{?__isa_bits} == 32 | |
1245 | # 32-bit builds can use 3G memory max, which is not enough even for -j2 | |
1246 | CEPH_SMP_NCPUS="1" | |
1247 | %endif | |
1248 | # do not eat all memory | |
1249 | echo "Available memory:" | |
1250 | free -h | |
1251 | echo "System limits:" | |
1252 | ulimit -a | |
1253 | if test -n "$CEPH_SMP_NCPUS" -a "$CEPH_SMP_NCPUS" -gt 1 ; then | |
eafe8130 | 1254 | mem_per_process=2500 |
11fdf7f2 TL |
1255 | max_mem=$(LANG=C free -m | sed -n "s|^Mem: *\([0-9]*\).*$|\1|p") |
1256 | max_jobs="$(($max_mem / $mem_per_process))" | |
1257 | test "$CEPH_SMP_NCPUS" -gt "$max_jobs" && CEPH_SMP_NCPUS="$max_jobs" && echo "Warning: Reducing build parallelism to -j$max_jobs because of memory limits" | |
1258 | test "$CEPH_SMP_NCPUS" -le 0 && CEPH_SMP_NCPUS="1" && echo "Warning: Not using parallel build at all because of memory limits" | |
1259 | fi | |
1260 | export CEPH_SMP_NCPUS | |
1261 | export CEPH_MFLAGS_JOBS="-j$CEPH_SMP_NCPUS" | |
7c673cae | 1262 | |
11fdf7f2 | 1263 | env | sort |
7c673cae FG |
1264 | |
1265 | mkdir build | |
1266 | cd build | |
11fdf7f2 | 1267 | CMAKE=cmake |
11fdf7f2 | 1268 | ${CMAKE} .. \ |
7c673cae FG |
1269 | -DCMAKE_INSTALL_PREFIX=%{_prefix} \ |
1270 | -DCMAKE_INSTALL_LIBDIR=%{_libdir} \ | |
1271 | -DCMAKE_INSTALL_LIBEXECDIR=%{_libexecdir} \ | |
1272 | -DCMAKE_INSTALL_LOCALSTATEDIR=%{_localstatedir} \ | |
1273 | -DCMAKE_INSTALL_SYSCONFDIR=%{_sysconfdir} \ | |
1274 | -DCMAKE_INSTALL_MANDIR=%{_mandir} \ | |
1275 | -DCMAKE_INSTALL_DOCDIR=%{_docdir}/ceph \ | |
c07f9fc5 | 1276 | -DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \ |
f67539c2 | 1277 | -DCMAKE_INSTALL_SYSTEMD_SERVICEDIR=%{_unitdir} \ |
7c673cae | 1278 | -DWITH_MANPAGE=ON \ |
11fdf7f2 TL |
1279 | -DWITH_PYTHON3=%{python3_version} \ |
1280 | -DWITH_MGR_DASHBOARD_FRONTEND=OFF \ | |
7c673cae FG |
1281 | %if 0%{without ceph_test_package} |
1282 | -DWITH_TESTS=OFF \ | |
1283 | %endif | |
1284 | %if 0%{with cephfs_java} | |
1285 | -DWITH_CEPHFS_JAVA=ON \ | |
1286 | %endif | |
1287 | %if 0%{with selinux} | |
1288 | -DWITH_SELINUX=ON \ | |
1289 | %endif | |
1290 | %if %{with lttng} | |
1291 | -DWITH_LTTNG=ON \ | |
c07f9fc5 | 1292 | -DWITH_BABELTRACE=ON \ |
7c673cae FG |
1293 | %else |
1294 | -DWITH_LTTNG=OFF \ | |
c07f9fc5 | 1295 | -DWITH_BABELTRACE=OFF \ |
7c673cae FG |
1296 | %endif |
1297 | $CEPH_EXTRA_CMAKE_ARGS \ | |
1298 | %if 0%{with ocf} | |
1299 | -DWITH_OCF=ON \ | |
31f18b77 | 1300 | %endif |
11fdf7f2 TL |
1301 | %if 0%{with cephfs_shell} |
1302 | -DWITH_CEPHFS_SHELL=ON \ | |
1303 | %endif | |
1304 | %if 0%{with libradosstriper} | |
1305 | -DWITH_LIBRADOSSTRIPER=ON \ | |
1306 | %else | |
1307 | -DWITH_LIBRADOSSTRIPER=OFF \ | |
1308 | %endif | |
1309 | %if 0%{with amqp_endpoint} | |
1310 | -DWITH_RADOSGW_AMQP_ENDPOINT=ON \ | |
1311 | %else | |
1312 | -DWITH_RADOSGW_AMQP_ENDPOINT=OFF \ | |
9f95a23c TL |
1313 | %endif |
1314 | %if 0%{with kafka_endpoint} | |
1315 | -DWITH_RADOSGW_KAFKA_ENDPOINT=ON \ | |
1316 | %else | |
1317 | -DWITH_RADOSGW_KAFKA_ENDPOINT=OFF \ | |
1318 | %endif | |
f67539c2 TL |
1319 | %if 0%{without lua_packages} |
1320 | -DWITH_RADOSGW_LUA_PACKAGES=OFF \ | |
1321 | %endif | |
1322 | %if 0%{with zbd} | |
1323 | -DWITH_ZBD=ON \ | |
1324 | %endif | |
9f95a23c TL |
1325 | %if 0%{with cmake_verbose_logging} |
1326 | -DCMAKE_VERBOSE_MAKEFILE=ON \ | |
f67539c2 TL |
1327 | %endif |
1328 | %if 0%{with rbd_rwl_cache} | |
1329 | -DWITH_RBD_RWL=ON \ | |
1330 | %endif | |
1331 | %if 0%{with rbd_ssd_cache} | |
1332 | -DWITH_RBD_SSD_CACHE=ON \ | |
1333 | %endif | |
1334 | %if 0%{?_system_pmdk} | |
1335 | -DWITH_SYSTEM_PMDK:BOOL=ON \ | |
11fdf7f2 TL |
1336 | %endif |
1337 | -DBOOST_J=$CEPH_SMP_NCPUS \ | |
1338 | -DWITH_GRAFANA=ON | |
7c673cae | 1339 | |
9f95a23c TL |
1340 | %if %{with cmake_verbose_logging} |
1341 | cat ./CMakeFiles/CMakeOutput.log | |
1342 | cat ./CMakeFiles/CMakeError.log | |
1343 | %endif | |
1344 | ||
11fdf7f2 | 1345 | make "$CEPH_MFLAGS_JOBS" |
7c673cae FG |
1346 | |
1347 | ||
1348 | %if 0%{with make_check} | |
1349 | %check | |
1350 | # run in-tree unittests | |
1351 | cd build | |
11fdf7f2 | 1352 | ctest "$CEPH_MFLAGS_JOBS" |
7c673cae FG |
1353 | %endif |
1354 | ||
1355 | ||
7c673cae FG |
1356 | %install |
1357 | pushd build | |
1358 | make DESTDIR=%{buildroot} install | |
1359 | # we have dropped sysvinit bits | |
1360 | rm -f %{buildroot}/%{_sysconfdir}/init.d/ceph | |
1361 | popd | |
f67539c2 TL |
1362 | |
1363 | %if 0%{with seastar} | |
1364 | # package crimson-osd with the name of ceph-osd | |
1365 | install -m 0755 %{buildroot}%{_bindir}/crimson-osd %{buildroot}%{_bindir}/ceph-osd | |
1366 | %endif | |
1367 | ||
7c673cae FG |
1368 | install -m 0644 -D src/etc-rbdmap %{buildroot}%{_sysconfdir}/ceph/rbdmap |
1369 | %if 0%{?fedora} || 0%{?rhel} | |
1370 | install -m 0644 -D etc/sysconfig/ceph %{buildroot}%{_sysconfdir}/sysconfig/ceph | |
1371 | %endif | |
1372 | %if 0%{?suse_version} | |
11fdf7f2 | 1373 | install -m 0644 -D etc/sysconfig/ceph %{buildroot}%{_fillupdir}/sysconfig.%{name} |
7c673cae FG |
1374 | %endif |
1375 | install -m 0644 -D systemd/ceph.tmpfiles.d %{buildroot}%{_tmpfilesdir}/ceph-common.conf | |
f67539c2 | 1376 | install -m 0644 -D systemd/50-ceph.preset %{buildroot}%{_presetdir}/50-ceph.preset |
7c673cae FG |
1377 | mkdir -p %{buildroot}%{_sbindir} |
1378 | install -m 0644 -D src/logrotate.conf %{buildroot}%{_sysconfdir}/logrotate.d/ceph | |
1379 | chmod 0644 %{buildroot}%{_docdir}/ceph/sample.ceph.conf | |
31f18b77 | 1380 | install -m 0644 -D COPYING %{buildroot}%{_docdir}/ceph/COPYING |
b32b8144 | 1381 | install -m 0644 -D etc/sysctl/90-ceph-osd.conf %{buildroot}%{_sysctldir}/90-ceph-osd.conf |
f67539c2 | 1382 | install -m 0755 -D src/tools/rbd_nbd/rbd-nbd_quiesce %{buildroot}%{_libexecdir}/rbd-nbd/rbd-nbd_quiesce |
7c673cae | 1383 | |
9f95a23c TL |
1384 | install -m 0755 src/cephadm/cephadm %{buildroot}%{_sbindir}/cephadm |
1385 | mkdir -p %{buildroot}%{_sharedstatedir}/cephadm | |
1386 | chmod 0700 %{buildroot}%{_sharedstatedir}/cephadm | |
1387 | mkdir -p %{buildroot}%{_sharedstatedir}/cephadm/.ssh | |
1388 | chmod 0700 %{buildroot}%{_sharedstatedir}/cephadm/.ssh | |
1389 | touch %{buildroot}%{_sharedstatedir}/cephadm/.ssh/authorized_keys | |
1390 | chmod 0600 %{buildroot}%{_sharedstatedir}/cephadm/.ssh/authorized_keys | |
1391 | ||
7c673cae | 1392 | # firewall templates and /sbin/mount.ceph symlink |
f67539c2 | 1393 | %if 0%{?suse_version} && !0%{?usrmerged} |
7c673cae FG |
1394 | mkdir -p %{buildroot}/sbin |
1395 | ln -sf %{_sbindir}/mount.ceph %{buildroot}/sbin/mount.ceph | |
1396 | %endif | |
1397 | ||
1398 | # udev rules | |
1399 | install -m 0644 -D udev/50-rbd.rules %{buildroot}%{_udevrulesdir}/50-rbd.rules | |
11fdf7f2 TL |
1400 | |
1401 | # sudoers.d | |
adb31ebb | 1402 | install -m 0440 -D sudoers.d/ceph-osd-smartctl %{buildroot}%{_sysconfdir}/sudoers.d/ceph-osd-smartctl |
9f95a23c TL |
1403 | |
1404 | %if 0%{?rhel} >= 8 | |
1405 | pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_bindir}/* | |
1406 | pathfix.py -pni "%{__python3} %{py3_shbang_opts}" %{buildroot}%{_sbindir}/* | |
1407 | %endif | |
7c673cae FG |
1408 | |
1409 | #set up placeholder directories | |
1410 | mkdir -p %{buildroot}%{_sysconfdir}/ceph | |
1411 | mkdir -p %{buildroot}%{_localstatedir}/run/ceph | |
1412 | mkdir -p %{buildroot}%{_localstatedir}/log/ceph | |
1413 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/tmp | |
1414 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mon | |
1415 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/osd | |
1416 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mds | |
1417 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/mgr | |
11fdf7f2 TL |
1418 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/crash |
1419 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/crash/posted | |
7c673cae FG |
1420 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/radosgw |
1421 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-osd | |
1422 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-mds | |
1423 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rgw | |
1424 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-mgr | |
d2e6a577 | 1425 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd |
11fdf7f2 | 1426 | mkdir -p %{buildroot}%{_localstatedir}/lib/ceph/bootstrap-rbd-mirror |
7c673cae | 1427 | |
801d1391 TL |
1428 | # prometheus alerts |
1429 | install -m 644 -D monitoring/prometheus/alerts/ceph_default_alerts.yml %{buildroot}/etc/prometheus/ceph/ceph_default_alerts.yml | |
1430 | ||
7c673cae FG |
1431 | %if 0%{?suse_version} |
1432 | # create __pycache__ directories and their contents | |
1433 | %py3_compile %{buildroot}%{python3_sitelib} | |
eafe8130 TL |
1434 | # hardlink duplicate files under /usr to save space |
1435 | %fdupes %{buildroot}%{_prefix} | |
7c673cae | 1436 | %endif |
eafe8130 | 1437 | |
11fdf7f2 TL |
1438 | %if 0%{?rhel} == 8 |
1439 | %py_byte_compile %{__python3} %{buildroot}%{python3_sitelib} | |
1440 | %endif | |
7c673cae FG |
1441 | |
1442 | %clean | |
1443 | rm -rf %{buildroot} | |
1444 | ||
1445 | ################################################################################# | |
1446 | # files and systemd scriptlets | |
1447 | ################################################################################# | |
1448 | %files | |
1449 | ||
1450 | %files base | |
11fdf7f2 | 1451 | %{_bindir}/ceph-crash |
7c673cae FG |
1452 | %{_bindir}/crushtool |
1453 | %{_bindir}/monmaptool | |
1454 | %{_bindir}/osdmaptool | |
b32b8144 | 1455 | %{_bindir}/ceph-kvstore-tool |
7c673cae | 1456 | %{_bindir}/ceph-run |
f67539c2 | 1457 | %{_presetdir}/50-ceph.preset |
7c673cae | 1458 | %{_sbindir}/ceph-create-keys |
7c673cae FG |
1459 | %dir %{_libexecdir}/ceph |
1460 | %{_libexecdir}/ceph/ceph_common.sh | |
1461 | %dir %{_libdir}/rados-classes | |
1462 | %{_libdir}/rados-classes/* | |
1463 | %dir %{_libdir}/ceph | |
1464 | %dir %{_libdir}/ceph/erasure-code | |
1465 | %{_libdir}/ceph/erasure-code/libec_*.so* | |
1466 | %dir %{_libdir}/ceph/compressor | |
1467 | %{_libdir}/ceph/compressor/libceph_*.so* | |
11fdf7f2 | 1468 | %{_unitdir}/ceph-crash.service |
7c673cae FG |
1469 | %dir %{_libdir}/ceph/crypto |
1470 | %{_libdir}/ceph/crypto/libceph_*.so* | |
7c673cae FG |
1471 | %if %{with lttng} |
1472 | %{_libdir}/libos_tp.so* | |
1473 | %{_libdir}/libosd_tp.so* | |
1474 | %endif | |
7c673cae FG |
1475 | %config(noreplace) %{_sysconfdir}/logrotate.d/ceph |
1476 | %if 0%{?fedora} || 0%{?rhel} | |
1477 | %config(noreplace) %{_sysconfdir}/sysconfig/ceph | |
1478 | %endif | |
1479 | %if 0%{?suse_version} | |
11fdf7f2 | 1480 | %{_fillupdir}/sysconfig.* |
7c673cae FG |
1481 | %endif |
1482 | %{_unitdir}/ceph.target | |
11fdf7f2 TL |
1483 | %dir %{python3_sitelib}/ceph_volume |
1484 | %{python3_sitelib}/ceph_volume/* | |
1485 | %{python3_sitelib}/ceph_volume-* | |
7c673cae | 1486 | %{_mandir}/man8/ceph-deploy.8* |
7c673cae FG |
1487 | %{_mandir}/man8/ceph-create-keys.8* |
1488 | %{_mandir}/man8/ceph-run.8* | |
1489 | %{_mandir}/man8/crushtool.8* | |
1490 | %{_mandir}/man8/osdmaptool.8* | |
1491 | %{_mandir}/man8/monmaptool.8* | |
b32b8144 | 1492 | %{_mandir}/man8/ceph-kvstore-tool.8* |
7c673cae | 1493 | #set up placeholder directories |
11fdf7f2 TL |
1494 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/crash |
1495 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/crash/posted | |
7c673cae FG |
1496 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/tmp |
1497 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-osd | |
1498 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-mds | |
1499 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rgw | |
1500 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-mgr | |
d2e6a577 | 1501 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd |
11fdf7f2 | 1502 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/bootstrap-rbd-mirror |
7c673cae FG |
1503 | |
1504 | %post base | |
1505 | /sbin/ldconfig | |
1506 | %if 0%{?suse_version} | |
1507 | %fillup_only | |
1508 | if [ $1 -eq 1 ] ; then | |
11fdf7f2 | 1509 | /usr/bin/systemctl preset ceph.target ceph-crash.service >/dev/null 2>&1 || : |
7c673cae FG |
1510 | fi |
1511 | %endif | |
1512 | %if 0%{?fedora} || 0%{?rhel} | |
11fdf7f2 | 1513 | %systemd_post ceph.target ceph-crash.service |
7c673cae FG |
1514 | %endif |
1515 | if [ $1 -eq 1 ] ; then | |
11fdf7f2 | 1516 | /usr/bin/systemctl start ceph.target ceph-crash.service >/dev/null 2>&1 || : |
7c673cae FG |
1517 | fi |
1518 | ||
1519 | %preun base | |
1520 | %if 0%{?suse_version} | |
11fdf7f2 | 1521 | %service_del_preun ceph.target ceph-crash.service |
7c673cae FG |
1522 | %endif |
1523 | %if 0%{?fedora} || 0%{?rhel} | |
11fdf7f2 | 1524 | %systemd_preun ceph.target ceph-crash.service |
7c673cae FG |
1525 | %endif |
1526 | ||
1527 | %postun base | |
1528 | /sbin/ldconfig | |
11fdf7f2 | 1529 | %systemd_postun ceph.target |
7c673cae | 1530 | |
9f95a23c TL |
1531 | %pre -n cephadm |
1532 | getent group cephadm >/dev/null || groupadd -r cephadm | |
1533 | getent passwd cephadm >/dev/null || useradd -r -g cephadm -s /bin/bash -c "cephadm user for mgr/cephadm" -d %{_sharedstatedir}/cephadm cephadm | |
1534 | exit 0 | |
1535 | ||
1536 | %if ! 0%{?suse_version} | |
1537 | %postun -n cephadm | |
1538 | userdel -r cephadm || true | |
1539 | exit 0 | |
1540 | %endif | |
1541 | ||
1542 | %files -n cephadm | |
1543 | %{_sbindir}/cephadm | |
1911f103 | 1544 | %{_mandir}/man8/cephadm.8* |
9f95a23c TL |
1545 | %attr(0700,cephadm,cephadm) %dir %{_sharedstatedir}/cephadm |
1546 | %attr(0700,cephadm,cephadm) %dir %{_sharedstatedir}/cephadm/.ssh | |
1547 | %attr(0600,cephadm,cephadm) %{_sharedstatedir}/cephadm/.ssh/authorized_keys | |
1548 | ||
7c673cae | 1549 | %files common |
224ce89b | 1550 | %dir %{_docdir}/ceph |
31f18b77 | 1551 | %doc %{_docdir}/ceph/sample.ceph.conf |
11fdf7f2 | 1552 | %license %{_docdir}/ceph/COPYING |
7c673cae FG |
1553 | %{_bindir}/ceph |
1554 | %{_bindir}/ceph-authtool | |
1555 | %{_bindir}/ceph-conf | |
1556 | %{_bindir}/ceph-dencoder | |
1557 | %{_bindir}/ceph-rbdnamer | |
1558 | %{_bindir}/ceph-syn | |
7c673cae FG |
1559 | %{_bindir}/cephfs-data-scan |
1560 | %{_bindir}/cephfs-journal-tool | |
1561 | %{_bindir}/cephfs-table-tool | |
1562 | %{_bindir}/rados | |
1563 | %{_bindir}/radosgw-admin | |
1564 | %{_bindir}/rbd | |
1565 | %{_bindir}/rbd-replay | |
1566 | %{_bindir}/rbd-replay-many | |
1567 | %{_bindir}/rbdmap | |
1568 | %{_sbindir}/mount.ceph | |
f67539c2 | 1569 | %if 0%{?suse_version} && !0%{?usrmerged} |
7c673cae FG |
1570 | /sbin/mount.ceph |
1571 | %endif | |
1572 | %if %{with lttng} | |
1573 | %{_bindir}/rbd-replay-prep | |
1574 | %endif | |
1575 | %{_bindir}/ceph-post-file | |
7c673cae FG |
1576 | %{_tmpfilesdir}/ceph-common.conf |
1577 | %{_mandir}/man8/ceph-authtool.8* | |
1578 | %{_mandir}/man8/ceph-conf.8* | |
1579 | %{_mandir}/man8/ceph-dencoder.8* | |
e306af50 | 1580 | %{_mandir}/man8/ceph-diff-sorted.8* |
7c673cae FG |
1581 | %{_mandir}/man8/ceph-rbdnamer.8* |
1582 | %{_mandir}/man8/ceph-syn.8* | |
1583 | %{_mandir}/man8/ceph-post-file.8* | |
1584 | %{_mandir}/man8/ceph.8* | |
1585 | %{_mandir}/man8/mount.ceph.8* | |
1586 | %{_mandir}/man8/rados.8* | |
1587 | %{_mandir}/man8/radosgw-admin.8* | |
1588 | %{_mandir}/man8/rbd.8* | |
1589 | %{_mandir}/man8/rbdmap.8* | |
1590 | %{_mandir}/man8/rbd-replay.8* | |
1591 | %{_mandir}/man8/rbd-replay-many.8* | |
1592 | %{_mandir}/man8/rbd-replay-prep.8* | |
e306af50 | 1593 | %{_mandir}/man8/rgw-orphan-list.8* |
7c673cae FG |
1594 | %dir %{_datadir}/ceph/ |
1595 | %{_datadir}/ceph/known_hosts_drop.ceph.com | |
1596 | %{_datadir}/ceph/id_rsa_drop.ceph.com | |
1597 | %{_datadir}/ceph/id_rsa_drop.ceph.com.pub | |
1598 | %dir %{_sysconfdir}/ceph/ | |
31f18b77 | 1599 | %config %{_sysconfdir}/bash_completion.d/ceph |
7c673cae FG |
1600 | %config %{_sysconfdir}/bash_completion.d/rados |
1601 | %config %{_sysconfdir}/bash_completion.d/rbd | |
1602 | %config %{_sysconfdir}/bash_completion.d/radosgw-admin | |
1603 | %config(noreplace) %{_sysconfdir}/ceph/rbdmap | |
1604 | %{_unitdir}/rbdmap.service | |
7c673cae FG |
1605 | %dir %{_udevrulesdir} |
1606 | %{_udevrulesdir}/50-rbd.rules | |
1607 | %attr(3770,ceph,ceph) %dir %{_localstatedir}/log/ceph/ | |
1608 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/ | |
1609 | ||
1610 | %pre common | |
1611 | CEPH_GROUP_ID=167 | |
1612 | CEPH_USER_ID=167 | |
1613 | %if 0%{?rhel} || 0%{?fedora} | |
1614 | /usr/sbin/groupadd ceph -g $CEPH_GROUP_ID -o -r 2>/dev/null || : | |
1615 | /usr/sbin/useradd ceph -u $CEPH_USER_ID -o -r -g ceph -s /sbin/nologin -c "Ceph daemons" -d %{_localstatedir}/lib/ceph 2>/dev/null || : | |
1616 | %endif | |
1617 | %if 0%{?suse_version} | |
1618 | if ! getent group ceph >/dev/null ; then | |
1619 | CEPH_GROUP_ID_OPTION="" | |
1620 | getent group $CEPH_GROUP_ID >/dev/null || CEPH_GROUP_ID_OPTION="-g $CEPH_GROUP_ID" | |
1621 | groupadd ceph $CEPH_GROUP_ID_OPTION -r 2>/dev/null || : | |
1622 | fi | |
1623 | if ! getent passwd ceph >/dev/null ; then | |
1624 | CEPH_USER_ID_OPTION="" | |
1625 | getent passwd $CEPH_USER_ID >/dev/null || CEPH_USER_ID_OPTION="-u $CEPH_USER_ID" | |
1626 | useradd ceph $CEPH_USER_ID_OPTION -r -g ceph -s /sbin/nologin 2>/dev/null || : | |
1627 | fi | |
1628 | usermod -c "Ceph storage service" \ | |
1629 | -d %{_localstatedir}/lib/ceph \ | |
1630 | -g ceph \ | |
1631 | -s /sbin/nologin \ | |
1632 | ceph | |
1633 | %endif | |
1634 | exit 0 | |
1635 | ||
1636 | %post common | |
1637 | %tmpfiles_create %{_tmpfilesdir}/ceph-common.conf | |
1638 | ||
1639 | %postun common | |
1640 | # Package removal cleanup | |
1641 | if [ "$1" -eq "0" ] ; then | |
1642 | rm -rf %{_localstatedir}/log/ceph | |
1643 | rm -rf %{_sysconfdir}/ceph | |
1644 | fi | |
1645 | ||
1646 | %files mds | |
1647 | %{_bindir}/ceph-mds | |
1648 | %{_mandir}/man8/ceph-mds.8* | |
1649 | %{_unitdir}/ceph-mds@.service | |
1650 | %{_unitdir}/ceph-mds.target | |
1651 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mds | |
1652 | ||
1653 | %post mds | |
1654 | %if 0%{?suse_version} | |
1655 | if [ $1 -eq 1 ] ; then | |
1656 | /usr/bin/systemctl preset ceph-mds@\*.service ceph-mds.target >/dev/null 2>&1 || : | |
1657 | fi | |
1658 | %endif | |
1659 | %if 0%{?fedora} || 0%{?rhel} | |
1660 | %systemd_post ceph-mds@\*.service ceph-mds.target | |
1661 | %endif | |
1662 | if [ $1 -eq 1 ] ; then | |
1663 | /usr/bin/systemctl start ceph-mds.target >/dev/null 2>&1 || : | |
1664 | fi | |
1665 | ||
1666 | %preun mds | |
1667 | %if 0%{?suse_version} | |
1668 | %service_del_preun ceph-mds@\*.service ceph-mds.target | |
1669 | %endif | |
1670 | %if 0%{?fedora} || 0%{?rhel} | |
1671 | %systemd_preun ceph-mds@\*.service ceph-mds.target | |
1672 | %endif | |
1673 | ||
1674 | %postun mds | |
7c673cae | 1675 | %systemd_postun ceph-mds@\*.service ceph-mds.target |
11fdf7f2 | 1676 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
1677 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
1678 | # "yes". In any case: if units are not running, do not touch them. | |
1679 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1680 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1681 | source $SYSCONF_CEPH | |
1682 | fi | |
1683 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
1684 | /usr/bin/systemctl try-restart ceph-mds@\*.service > /dev/null 2>&1 || : | |
1685 | fi | |
1686 | fi | |
1687 | ||
1688 | %files mgr | |
1689 | %{_bindir}/ceph-mgr | |
11fdf7f2 | 1690 | %dir %{_datadir}/ceph/mgr |
11fdf7f2 TL |
1691 | %{_datadir}/ceph/mgr/mgr_module.* |
1692 | %{_datadir}/ceph/mgr/mgr_util.* | |
7c673cae FG |
1693 | %{_unitdir}/ceph-mgr@.service |
1694 | %{_unitdir}/ceph-mgr.target | |
1695 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mgr | |
1696 | ||
1697 | %post mgr | |
1698 | %if 0%{?suse_version} | |
1699 | if [ $1 -eq 1 ] ; then | |
1700 | /usr/bin/systemctl preset ceph-mgr@\*.service ceph-mgr.target >/dev/null 2>&1 || : | |
1701 | fi | |
1702 | %endif | |
1703 | %if 0%{?fedora} || 0%{?rhel} | |
1704 | %systemd_post ceph-mgr@\*.service ceph-mgr.target | |
1705 | %endif | |
1706 | if [ $1 -eq 1 ] ; then | |
1707 | /usr/bin/systemctl start ceph-mgr.target >/dev/null 2>&1 || : | |
1708 | fi | |
1709 | ||
1710 | %preun mgr | |
1711 | %if 0%{?suse_version} | |
1712 | %service_del_preun ceph-mgr@\*.service ceph-mgr.target | |
1713 | %endif | |
1714 | %if 0%{?fedora} || 0%{?rhel} | |
1715 | %systemd_preun ceph-mgr@\*.service ceph-mgr.target | |
1716 | %endif | |
1717 | ||
1718 | %postun mgr | |
7c673cae | 1719 | %systemd_postun ceph-mgr@\*.service ceph-mgr.target |
11fdf7f2 | 1720 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
1721 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
1722 | # "yes". In any case: if units are not running, do not touch them. | |
1723 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1724 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1725 | source $SYSCONF_CEPH | |
1726 | fi | |
1727 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
1728 | /usr/bin/systemctl try-restart ceph-mgr@\*.service > /dev/null 2>&1 || : | |
1729 | fi | |
1730 | fi | |
1731 | ||
11fdf7f2 TL |
1732 | %files mgr-dashboard |
1733 | %{_datadir}/ceph/mgr/dashboard | |
1734 | ||
1735 | %post mgr-dashboard | |
1736 | if [ $1 -eq 1 ] ; then | |
1737 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1738 | fi | |
1739 | ||
1740 | %postun mgr-dashboard | |
1741 | if [ $1 -eq 1 ] ; then | |
1742 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1743 | fi | |
1744 | ||
1745 | %files mgr-diskprediction-local | |
1746 | %{_datadir}/ceph/mgr/diskprediction_local | |
1747 | ||
1748 | %post mgr-diskprediction-local | |
1749 | if [ $1 -eq 1 ] ; then | |
1750 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1751 | fi | |
1752 | ||
1753 | %postun mgr-diskprediction-local | |
1754 | if [ $1 -eq 1 ] ; then | |
1755 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1756 | fi | |
1757 | ||
9f95a23c TL |
1758 | %files mgr-modules-core |
1759 | %dir %{_datadir}/ceph/mgr | |
1760 | %{_datadir}/ceph/mgr/alerts | |
1761 | %{_datadir}/ceph/mgr/balancer | |
1762 | %{_datadir}/ceph/mgr/crash | |
1763 | %{_datadir}/ceph/mgr/devicehealth | |
1764 | %{_datadir}/ceph/mgr/influx | |
1765 | %{_datadir}/ceph/mgr/insights | |
1766 | %{_datadir}/ceph/mgr/iostat | |
1767 | %{_datadir}/ceph/mgr/localpool | |
f67539c2 TL |
1768 | %{_datadir}/ceph/mgr/mds_autoscaler |
1769 | %{_datadir}/ceph/mgr/mirroring | |
9f95a23c TL |
1770 | %{_datadir}/ceph/mgr/orchestrator |
1771 | %{_datadir}/ceph/mgr/osd_perf_query | |
1772 | %{_datadir}/ceph/mgr/osd_support | |
1773 | %{_datadir}/ceph/mgr/pg_autoscaler | |
1774 | %{_datadir}/ceph/mgr/progress | |
1775 | %{_datadir}/ceph/mgr/prometheus | |
1776 | %{_datadir}/ceph/mgr/rbd_support | |
1777 | %{_datadir}/ceph/mgr/restful | |
1778 | %{_datadir}/ceph/mgr/selftest | |
f67539c2 TL |
1779 | %{_datadir}/ceph/mgr/snap_schedule |
1780 | %{_datadir}/ceph/mgr/stats | |
9f95a23c TL |
1781 | %{_datadir}/ceph/mgr/status |
1782 | %{_datadir}/ceph/mgr/telegraf | |
1783 | %{_datadir}/ceph/mgr/telemetry | |
1784 | %{_datadir}/ceph/mgr/test_orchestrator | |
1785 | %{_datadir}/ceph/mgr/volumes | |
1786 | %{_datadir}/ceph/mgr/zabbix | |
1787 | ||
11fdf7f2 TL |
1788 | %files mgr-rook |
1789 | %{_datadir}/ceph/mgr/rook | |
1790 | ||
1791 | %post mgr-rook | |
1792 | if [ $1 -eq 1 ] ; then | |
1793 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1794 | fi | |
1795 | ||
1796 | %postun mgr-rook | |
1797 | if [ $1 -eq 1 ] ; then | |
1798 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1799 | fi | |
1800 | ||
eafe8130 TL |
1801 | %files mgr-k8sevents |
1802 | %{_datadir}/ceph/mgr/k8sevents | |
1803 | ||
1804 | %post mgr-k8sevents | |
1805 | if [ $1 -eq 1 ] ; then | |
1806 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1807 | fi | |
1808 | ||
1809 | %postun mgr-k8sevents | |
1810 | if [ $1 -eq 1 ] ; then | |
1811 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1812 | fi | |
1813 | ||
9f95a23c TL |
1814 | %files mgr-cephadm |
1815 | %{_datadir}/ceph/mgr/cephadm | |
11fdf7f2 | 1816 | |
9f95a23c | 1817 | %post mgr-cephadm |
11fdf7f2 TL |
1818 | if [ $1 -eq 1 ] ; then |
1819 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1820 | fi | |
1821 | ||
9f95a23c | 1822 | %postun mgr-cephadm |
11fdf7f2 TL |
1823 | if [ $1 -eq 1 ] ; then |
1824 | /usr/bin/systemctl try-restart ceph-mgr.target >/dev/null 2>&1 || : | |
1825 | fi | |
1826 | ||
7c673cae FG |
1827 | %files mon |
1828 | %{_bindir}/ceph-mon | |
b32b8144 | 1829 | %{_bindir}/ceph-monstore-tool |
7c673cae | 1830 | %{_mandir}/man8/ceph-mon.8* |
7c673cae FG |
1831 | %{_unitdir}/ceph-mon@.service |
1832 | %{_unitdir}/ceph-mon.target | |
1833 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/mon | |
1834 | ||
1835 | %post mon | |
1836 | %if 0%{?suse_version} | |
1837 | if [ $1 -eq 1 ] ; then | |
1838 | /usr/bin/systemctl preset ceph-mon@\*.service ceph-mon.target >/dev/null 2>&1 || : | |
1839 | fi | |
1840 | %endif | |
1841 | %if 0%{?fedora} || 0%{?rhel} | |
1842 | %systemd_post ceph-mon@\*.service ceph-mon.target | |
1843 | %endif | |
1844 | if [ $1 -eq 1 ] ; then | |
1845 | /usr/bin/systemctl start ceph-mon.target >/dev/null 2>&1 || : | |
1846 | fi | |
1847 | ||
1848 | %preun mon | |
1849 | %if 0%{?suse_version} | |
1850 | %service_del_preun ceph-mon@\*.service ceph-mon.target | |
1851 | %endif | |
1852 | %if 0%{?fedora} || 0%{?rhel} | |
1853 | %systemd_preun ceph-mon@\*.service ceph-mon.target | |
1854 | %endif | |
1855 | ||
1856 | %postun mon | |
7c673cae | 1857 | %systemd_postun ceph-mon@\*.service ceph-mon.target |
11fdf7f2 | 1858 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
1859 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
1860 | # "yes". In any case: if units are not running, do not touch them. | |
1861 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1862 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1863 | source $SYSCONF_CEPH | |
1864 | fi | |
1865 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
1866 | /usr/bin/systemctl try-restart ceph-mon@\*.service > /dev/null 2>&1 || : | |
1867 | fi | |
1868 | fi | |
1869 | ||
1870 | %files fuse | |
7c673cae FG |
1871 | %{_bindir}/ceph-fuse |
1872 | %{_mandir}/man8/ceph-fuse.8* | |
1873 | %{_sbindir}/mount.fuse.ceph | |
f67539c2 | 1874 | %{_mandir}/man8/mount.fuse.ceph.8* |
7c673cae FG |
1875 | %{_unitdir}/ceph-fuse@.service |
1876 | %{_unitdir}/ceph-fuse.target | |
1877 | ||
f67539c2 TL |
1878 | %files -n cephfs-mirror |
1879 | %{_bindir}/cephfs-mirror | |
1880 | %{_mandir}/man8/cephfs-mirror.8* | |
1881 | %{_unitdir}/cephfs-mirror@.service | |
1882 | %{_unitdir}/cephfs-mirror.target | |
1883 | ||
1884 | %post -n cephfs-mirror | |
1885 | %if 0%{?suse_version} | |
1886 | if [ $1 -eq 1 ] ; then | |
1887 | /usr/bin/systemctl preset cephfs-mirror@\*.service cephfs-mirror.target >/dev/null 2>&1 || : | |
1888 | fi | |
1889 | %endif | |
1890 | %if 0%{?fedora} || 0%{?rhel} | |
1891 | %systemd_post cephfs-mirror@\*.service cephfs-mirror.target | |
1892 | %endif | |
1893 | if [ $1 -eq 1 ] ; then | |
1894 | /usr/bin/systemctl start cephfs-mirror.target >/dev/null 2>&1 || : | |
1895 | fi | |
1896 | ||
1897 | %preun -n cephfs-mirror | |
1898 | %if 0%{?suse_version} | |
1899 | %service_del_preun cephfs-mirror@\*.service cephfs-mirror.target | |
1900 | %endif | |
1901 | %if 0%{?fedora} || 0%{?rhel} | |
1902 | %systemd_preun cephfs-mirror@\*.service cephfs-mirror.target | |
1903 | %endif | |
1904 | ||
1905 | %postun -n cephfs-mirror | |
1906 | %systemd_postun cephfs-mirror@\*.service cephfs-mirror.target | |
1907 | if [ $1 -ge 1 ] ; then | |
1908 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to | |
1909 | # "yes". In any case: if units are not running, do not touch them. | |
1910 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1911 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1912 | source $SYSCONF_CEPH | |
1913 | fi | |
1914 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
1915 | /usr/bin/systemctl try-restart cephfs-mirror@\*.service > /dev/null 2>&1 || : | |
1916 | fi | |
1917 | fi | |
1918 | ||
7c673cae | 1919 | %files -n rbd-fuse |
7c673cae FG |
1920 | %{_bindir}/rbd-fuse |
1921 | %{_mandir}/man8/rbd-fuse.8* | |
1922 | ||
1923 | %files -n rbd-mirror | |
7c673cae FG |
1924 | %{_bindir}/rbd-mirror |
1925 | %{_mandir}/man8/rbd-mirror.8* | |
1926 | %{_unitdir}/ceph-rbd-mirror@.service | |
1927 | %{_unitdir}/ceph-rbd-mirror.target | |
1928 | ||
1929 | %post -n rbd-mirror | |
1930 | %if 0%{?suse_version} | |
1931 | if [ $1 -eq 1 ] ; then | |
1932 | /usr/bin/systemctl preset ceph-rbd-mirror@\*.service ceph-rbd-mirror.target >/dev/null 2>&1 || : | |
1933 | fi | |
1934 | %endif | |
1935 | %if 0%{?fedora} || 0%{?rhel} | |
1936 | %systemd_post ceph-rbd-mirror@\*.service ceph-rbd-mirror.target | |
1937 | %endif | |
1938 | if [ $1 -eq 1 ] ; then | |
1939 | /usr/bin/systemctl start ceph-rbd-mirror.target >/dev/null 2>&1 || : | |
1940 | fi | |
1941 | ||
1942 | %preun -n rbd-mirror | |
1943 | %if 0%{?suse_version} | |
1944 | %service_del_preun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target | |
1945 | %endif | |
1946 | %if 0%{?fedora} || 0%{?rhel} | |
1947 | %systemd_preun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target | |
1948 | %endif | |
1949 | ||
1950 | %postun -n rbd-mirror | |
7c673cae | 1951 | %systemd_postun ceph-rbd-mirror@\*.service ceph-rbd-mirror.target |
11fdf7f2 | 1952 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
1953 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
1954 | # "yes". In any case: if units are not running, do not touch them. | |
1955 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1956 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1957 | source $SYSCONF_CEPH | |
1958 | fi | |
1959 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
1960 | /usr/bin/systemctl try-restart ceph-rbd-mirror@\*.service > /dev/null 2>&1 || : | |
1961 | fi | |
1962 | fi | |
1963 | ||
9f95a23c TL |
1964 | %files immutable-object-cache |
1965 | %{_bindir}/ceph-immutable-object-cache | |
1966 | %{_mandir}/man8/ceph-immutable-object-cache.8* | |
1967 | %{_unitdir}/ceph-immutable-object-cache@.service | |
1968 | %{_unitdir}/ceph-immutable-object-cache.target | |
1969 | ||
1970 | %post immutable-object-cache | |
1971 | %if 0%{?suse_version} | |
1972 | if [ $1 -eq 1 ] ; then | |
1973 | /usr/bin/systemctl preset ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target >/dev/null 2>&1 || : | |
1974 | fi | |
1975 | %endif | |
1976 | %if 0%{?fedora} || 0%{?rhel} | |
1977 | %systemd_post ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target | |
1978 | %endif | |
1979 | if [ $1 -eq 1 ] ; then | |
1980 | /usr/bin/systemctl start ceph-immutable-object-cache.target >/dev/null 2>&1 || : | |
1981 | fi | |
1982 | ||
1983 | %preun immutable-object-cache | |
1984 | %if 0%{?suse_version} | |
1985 | %service_del_preun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target | |
1986 | %endif | |
1987 | %if 0%{?fedora} || 0%{?rhel} | |
1988 | %systemd_preun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target | |
1989 | %endif | |
1990 | ||
1991 | %postun immutable-object-cache | |
1992 | test -n "$FIRST_ARG" || FIRST_ARG=$1 | |
9f95a23c | 1993 | %systemd_postun ceph-immutable-object-cache@\*.service ceph-immutable-object-cache.target |
9f95a23c TL |
1994 | if [ $FIRST_ARG -ge 1 ] ; then |
1995 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to | |
1996 | # "yes". In any case: if units are not running, do not touch them. | |
1997 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
1998 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
1999 | source $SYSCONF_CEPH | |
2000 | fi | |
2001 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
2002 | /usr/bin/systemctl try-restart ceph-immutable-object-cache@\*.service > /dev/null 2>&1 || : | |
2003 | fi | |
2004 | fi | |
2005 | ||
7c673cae | 2006 | %files -n rbd-nbd |
7c673cae FG |
2007 | %{_bindir}/rbd-nbd |
2008 | %{_mandir}/man8/rbd-nbd.8* | |
f67539c2 TL |
2009 | %dir %{_libexecdir}/rbd-nbd |
2010 | %{_libexecdir}/rbd-nbd/rbd-nbd_quiesce | |
7c673cae FG |
2011 | |
2012 | %files radosgw | |
e306af50 | 2013 | %{_bindir}/ceph-diff-sorted |
7c673cae FG |
2014 | %{_bindir}/radosgw |
2015 | %{_bindir}/radosgw-token | |
31f18b77 | 2016 | %{_bindir}/radosgw-es |
7c673cae | 2017 | %{_bindir}/radosgw-object-expirer |
f67539c2 TL |
2018 | %{_bindir}/rgw-gap-list |
2019 | %{_bindir}/rgw-gap-list-comparator | |
e306af50 | 2020 | %{_bindir}/rgw-orphan-list |
9f95a23c | 2021 | %{_libdir}/libradosgw.so* |
7c673cae FG |
2022 | %{_mandir}/man8/radosgw.8* |
2023 | %dir %{_localstatedir}/lib/ceph/radosgw | |
2024 | %{_unitdir}/ceph-radosgw@.service | |
2025 | %{_unitdir}/ceph-radosgw.target | |
2026 | ||
2027 | %post radosgw | |
9f95a23c | 2028 | /sbin/ldconfig |
7c673cae FG |
2029 | %if 0%{?suse_version} |
2030 | if [ $1 -eq 1 ] ; then | |
2031 | /usr/bin/systemctl preset ceph-radosgw@\*.service ceph-radosgw.target >/dev/null 2>&1 || : | |
2032 | fi | |
2033 | %endif | |
2034 | %if 0%{?fedora} || 0%{?rhel} | |
2035 | %systemd_post ceph-radosgw@\*.service ceph-radosgw.target | |
2036 | %endif | |
2037 | if [ $1 -eq 1 ] ; then | |
2038 | /usr/bin/systemctl start ceph-radosgw.target >/dev/null 2>&1 || : | |
2039 | fi | |
2040 | ||
2041 | %preun radosgw | |
2042 | %if 0%{?suse_version} | |
2043 | %service_del_preun ceph-radosgw@\*.service ceph-radosgw.target | |
2044 | %endif | |
2045 | %if 0%{?fedora} || 0%{?rhel} | |
2046 | %systemd_preun ceph-radosgw@\*.service ceph-radosgw.target | |
2047 | %endif | |
2048 | ||
2049 | %postun radosgw | |
9f95a23c | 2050 | /sbin/ldconfig |
7c673cae | 2051 | %systemd_postun ceph-radosgw@\*.service ceph-radosgw.target |
11fdf7f2 | 2052 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
2053 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
2054 | # "yes". In any case: if units are not running, do not touch them. | |
2055 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
2056 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
2057 | source $SYSCONF_CEPH | |
2058 | fi | |
2059 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
2060 | /usr/bin/systemctl try-restart ceph-radosgw@\*.service > /dev/null 2>&1 || : | |
2061 | fi | |
2062 | fi | |
2063 | ||
2064 | %files osd | |
2065 | %{_bindir}/ceph-clsinfo | |
2066 | %{_bindir}/ceph-bluestore-tool | |
f67539c2 | 2067 | %{_bindir}/ceph-erasure-code-tool |
7c673cae | 2068 | %{_bindir}/ceph-objectstore-tool |
b32b8144 | 2069 | %{_bindir}/ceph-osdomap-tool |
7c673cae | 2070 | %{_bindir}/ceph-osd |
7c673cae | 2071 | %{_libexecdir}/ceph/ceph-osd-prestart.sh |
b32b8144 FG |
2072 | %{_sbindir}/ceph-volume |
2073 | %{_sbindir}/ceph-volume-systemd | |
7c673cae | 2074 | %{_mandir}/man8/ceph-clsinfo.8* |
7c673cae | 2075 | %{_mandir}/man8/ceph-osd.8* |
3efd9988 | 2076 | %{_mandir}/man8/ceph-bluestore-tool.8* |
b32b8144 FG |
2077 | %{_mandir}/man8/ceph-volume.8* |
2078 | %{_mandir}/man8/ceph-volume-systemd.8* | |
7c673cae FG |
2079 | %{_unitdir}/ceph-osd@.service |
2080 | %{_unitdir}/ceph-osd.target | |
b32b8144 | 2081 | %{_unitdir}/ceph-volume@.service |
7c673cae | 2082 | %attr(750,ceph,ceph) %dir %{_localstatedir}/lib/ceph/osd |
3efd9988 | 2083 | %config(noreplace) %{_sysctldir}/90-ceph-osd.conf |
11fdf7f2 | 2084 | %{_sysconfdir}/sudoers.d/ceph-osd-smartctl |
7c673cae FG |
2085 | |
2086 | %post osd | |
2087 | %if 0%{?suse_version} | |
2088 | if [ $1 -eq 1 ] ; then | |
b32b8144 | 2089 | /usr/bin/systemctl preset ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target >/dev/null 2>&1 || : |
7c673cae FG |
2090 | fi |
2091 | %endif | |
2092 | %if 0%{?fedora} || 0%{?rhel} | |
b32b8144 | 2093 | %systemd_post ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target |
7c673cae FG |
2094 | %endif |
2095 | if [ $1 -eq 1 ] ; then | |
2096 | /usr/bin/systemctl start ceph-osd.target >/dev/null 2>&1 || : | |
2097 | fi | |
3efd9988 FG |
2098 | %if 0%{?sysctl_apply} |
2099 | %sysctl_apply 90-ceph-osd.conf | |
2100 | %else | |
2101 | /usr/lib/systemd/systemd-sysctl %{_sysctldir}/90-ceph-osd.conf > /dev/null 2>&1 || : | |
2102 | %endif | |
7c673cae FG |
2103 | |
2104 | %preun osd | |
2105 | %if 0%{?suse_version} | |
b32b8144 | 2106 | %service_del_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target |
7c673cae FG |
2107 | %endif |
2108 | %if 0%{?fedora} || 0%{?rhel} | |
b32b8144 | 2109 | %systemd_preun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target |
7c673cae FG |
2110 | %endif |
2111 | ||
2112 | %postun osd | |
b32b8144 | 2113 | %systemd_postun ceph-osd@\*.service ceph-volume@\*.service ceph-osd.target |
11fdf7f2 | 2114 | if [ $1 -ge 1 ] ; then |
7c673cae FG |
2115 | # Restart on upgrade, but only if "CEPH_AUTO_RESTART_ON_UPGRADE" is set to |
2116 | # "yes". In any case: if units are not running, do not touch them. | |
2117 | SYSCONF_CEPH=%{_sysconfdir}/sysconfig/ceph | |
2118 | if [ -f $SYSCONF_CEPH -a -r $SYSCONF_CEPH ] ; then | |
2119 | source $SYSCONF_CEPH | |
2120 | fi | |
2121 | if [ "X$CEPH_AUTO_RESTART_ON_UPGRADE" = "Xyes" ] ; then | |
b32b8144 | 2122 | /usr/bin/systemctl try-restart ceph-osd@\*.service ceph-volume@\*.service > /dev/null 2>&1 || : |
7c673cae FG |
2123 | fi |
2124 | fi | |
2125 | ||
9f95a23c TL |
2126 | %if 0%{with seastar} |
2127 | %files crimson-osd | |
2128 | %{_bindir}/crimson-osd | |
2129 | %endif | |
2130 | ||
7c673cae FG |
2131 | %if %{with ocf} |
2132 | ||
2133 | %files resource-agents | |
7c673cae FG |
2134 | %dir %{_prefix}/lib/ocf |
2135 | %dir %{_prefix}/lib/ocf/resource.d | |
2136 | %dir %{_prefix}/lib/ocf/resource.d/ceph | |
b32b8144 | 2137 | %attr(0755,-,-) %{_prefix}/lib/ocf/resource.d/ceph/rbd |
7c673cae FG |
2138 | |
2139 | %endif | |
2140 | ||
2141 | %files -n librados2 | |
7c673cae FG |
2142 | %{_libdir}/librados.so.* |
2143 | %dir %{_libdir}/ceph | |
11fdf7f2 | 2144 | %{_libdir}/ceph/libceph-common.so.* |
7c673cae FG |
2145 | %if %{with lttng} |
2146 | %{_libdir}/librados_tp.so.* | |
2147 | %endif | |
eafe8130 | 2148 | %dir %{_sysconfdir}/ceph |
7c673cae FG |
2149 | |
2150 | %post -n librados2 -p /sbin/ldconfig | |
2151 | ||
2152 | %postun -n librados2 -p /sbin/ldconfig | |
2153 | ||
2154 | %files -n librados-devel | |
7c673cae FG |
2155 | %dir %{_includedir}/rados |
2156 | %{_includedir}/rados/librados.h | |
7c673cae | 2157 | %{_includedir}/rados/rados_types.h |
7c673cae FG |
2158 | %{_libdir}/librados.so |
2159 | %if %{with lttng} | |
2160 | %{_libdir}/librados_tp.so | |
2161 | %endif | |
2162 | %{_bindir}/librados-config | |
2163 | %{_mandir}/man8/librados-config.8* | |
2164 | ||
11fdf7f2 TL |
2165 | %files -n libradospp-devel |
2166 | %dir %{_includedir}/rados | |
2167 | %{_includedir}/rados/buffer.h | |
2168 | %{_includedir}/rados/buffer_fwd.h | |
2169 | %{_includedir}/rados/crc32c.h | |
2170 | %{_includedir}/rados/inline_memory.h | |
2171 | %{_includedir}/rados/librados.hpp | |
2172 | %{_includedir}/rados/librados_fwd.hpp | |
2173 | %{_includedir}/rados/page.h | |
2174 | %{_includedir}/rados/rados_types.hpp | |
2175 | ||
7c673cae | 2176 | %files -n python%{python3_pkgversion}-rados |
7c673cae FG |
2177 | %{python3_sitearch}/rados.cpython*.so |
2178 | %{python3_sitearch}/rados-*.egg-info | |
2179 | ||
f67539c2 TL |
2180 | %files -n libcephsqlite |
2181 | %{_libdir}/libcephsqlite.so | |
2182 | ||
2183 | %post -n libcephsqlite -p /sbin/ldconfig | |
2184 | ||
2185 | %postun -n libcephsqlite -p /sbin/ldconfig | |
2186 | ||
2187 | %files -n libcephsqlite-devel | |
2188 | %{_includedir}/libcephsqlite.h | |
2189 | ||
11fdf7f2 | 2190 | %if 0%{with libradosstriper} |
7c673cae | 2191 | %files -n libradosstriper1 |
7c673cae FG |
2192 | %{_libdir}/libradosstriper.so.* |
2193 | ||
2194 | %post -n libradosstriper1 -p /sbin/ldconfig | |
2195 | ||
2196 | %postun -n libradosstriper1 -p /sbin/ldconfig | |
2197 | ||
2198 | %files -n libradosstriper-devel | |
7c673cae FG |
2199 | %dir %{_includedir}/radosstriper |
2200 | %{_includedir}/radosstriper/libradosstriper.h | |
2201 | %{_includedir}/radosstriper/libradosstriper.hpp | |
2202 | %{_libdir}/libradosstriper.so | |
11fdf7f2 | 2203 | %endif |
7c673cae FG |
2204 | |
2205 | %files -n librbd1 | |
7c673cae FG |
2206 | %{_libdir}/librbd.so.* |
2207 | %if %{with lttng} | |
2208 | %{_libdir}/librbd_tp.so.* | |
2209 | %endif | |
f67539c2 TL |
2210 | %dir %{_libdir}/ceph/librbd |
2211 | %{_libdir}/ceph/librbd/libceph_*.so* | |
7c673cae | 2212 | |
181888fb | 2213 | %post -n librbd1 -p /sbin/ldconfig |
7c673cae FG |
2214 | |
2215 | %postun -n librbd1 -p /sbin/ldconfig | |
2216 | ||
2217 | %files -n librbd-devel | |
7c673cae FG |
2218 | %dir %{_includedir}/rbd |
2219 | %{_includedir}/rbd/librbd.h | |
2220 | %{_includedir}/rbd/librbd.hpp | |
2221 | %{_includedir}/rbd/features.h | |
2222 | %{_libdir}/librbd.so | |
2223 | %if %{with lttng} | |
2224 | %{_libdir}/librbd_tp.so | |
2225 | %endif | |
2226 | ||
2227 | %files -n librgw2 | |
7c673cae | 2228 | %{_libdir}/librgw.so.* |
11fdf7f2 | 2229 | %if %{with lttng} |
eafe8130 TL |
2230 | %{_libdir}/librgw_op_tp.so.* |
2231 | %{_libdir}/librgw_rados_tp.so.* | |
11fdf7f2 | 2232 | %endif |
7c673cae FG |
2233 | |
2234 | %post -n librgw2 -p /sbin/ldconfig | |
2235 | ||
2236 | %postun -n librgw2 -p /sbin/ldconfig | |
2237 | ||
2238 | %files -n librgw-devel | |
7c673cae FG |
2239 | %dir %{_includedir}/rados |
2240 | %{_includedir}/rados/librgw.h | |
2241 | %{_includedir}/rados/rgw_file.h | |
2242 | %{_libdir}/librgw.so | |
eafe8130 TL |
2243 | %if %{with lttng} |
2244 | %{_libdir}/librgw_op_tp.so | |
2245 | %{_libdir}/librgw_rados_tp.so | |
2246 | %endif | |
7c673cae | 2247 | |
7c673cae | 2248 | %files -n python%{python3_pkgversion}-rgw |
7c673cae FG |
2249 | %{python3_sitearch}/rgw.cpython*.so |
2250 | %{python3_sitearch}/rgw-*.egg-info | |
2251 | ||
7c673cae | 2252 | %files -n python%{python3_pkgversion}-rbd |
7c673cae FG |
2253 | %{python3_sitearch}/rbd.cpython*.so |
2254 | %{python3_sitearch}/rbd-*.egg-info | |
2255 | ||
2256 | %files -n libcephfs2 | |
7c673cae | 2257 | %{_libdir}/libcephfs.so.* |
eafe8130 | 2258 | %dir %{_sysconfdir}/ceph |
7c673cae FG |
2259 | |
2260 | %post -n libcephfs2 -p /sbin/ldconfig | |
2261 | ||
2262 | %postun -n libcephfs2 -p /sbin/ldconfig | |
2263 | ||
2264 | %files -n libcephfs-devel | |
7c673cae FG |
2265 | %dir %{_includedir}/cephfs |
2266 | %{_includedir}/cephfs/libcephfs.h | |
e306af50 | 2267 | %{_includedir}/cephfs/ceph_ll_client.h |
f67539c2 TL |
2268 | %dir %{_includedir}/cephfs/metrics |
2269 | %{_includedir}/cephfs/metrics/Types.h | |
7c673cae FG |
2270 | %{_libdir}/libcephfs.so |
2271 | ||
f67539c2 TL |
2272 | %if %{with jaeger} |
2273 | %files -n libjaeger | |
2274 | %{_libdir}/libopentracing.so.* | |
2275 | %{_libdir}/libthrift.so.* | |
2276 | %{_libdir}/libjaegertracing.so.* | |
2277 | %post -n libjaeger -p /sbin/ldconfig | |
2278 | %postun -n libjaeger -p /sbin/ldconfig | |
2279 | %endif | |
2280 | ||
7c673cae | 2281 | %files -n python%{python3_pkgversion}-cephfs |
7c673cae FG |
2282 | %{python3_sitearch}/cephfs.cpython*.so |
2283 | %{python3_sitearch}/cephfs-*.egg-info | |
2284 | %{python3_sitelib}/ceph_volume_client.py | |
2285 | %{python3_sitelib}/__pycache__/ceph_volume_client.cpython*.py* | |
2286 | ||
2287 | %files -n python%{python3_pkgversion}-ceph-argparse | |
7c673cae FG |
2288 | %{python3_sitelib}/ceph_argparse.py |
2289 | %{python3_sitelib}/__pycache__/ceph_argparse.cpython*.py* | |
2290 | %{python3_sitelib}/ceph_daemon.py | |
2291 | %{python3_sitelib}/__pycache__/ceph_daemon.cpython*.py* | |
2292 | ||
9f95a23c TL |
2293 | %files -n python%{python3_pkgversion}-ceph-common |
2294 | %{python3_sitelib}/ceph | |
2295 | %{python3_sitelib}/ceph-*.egg-info | |
2296 | ||
11fdf7f2 TL |
2297 | %if 0%{with cephfs_shell} |
2298 | %files -n cephfs-shell | |
2299 | %{python3_sitelib}/cephfs_shell-*.egg-info | |
2300 | %{_bindir}/cephfs-shell | |
2301 | %endif | |
2302 | ||
f67539c2 TL |
2303 | %files -n cephfs-top |
2304 | %{python3_sitelib}/cephfs_top-*.egg-info | |
2305 | %{_bindir}/cephfs-top | |
2306 | %{_mandir}/man8/cephfs-top.8* | |
2307 | ||
7c673cae FG |
2308 | %if 0%{with ceph_test_package} |
2309 | %files -n ceph-test | |
7c673cae FG |
2310 | %{_bindir}/ceph-client-debug |
2311 | %{_bindir}/ceph_bench_log | |
2312 | %{_bindir}/ceph_kvstorebench | |
2313 | %{_bindir}/ceph_multi_stress_watch | |
7c673cae FG |
2314 | %{_bindir}/ceph_erasure_code_benchmark |
2315 | %{_bindir}/ceph_omapbench | |
2316 | %{_bindir}/ceph_objectstore_bench | |
2317 | %{_bindir}/ceph_perf_objectstore | |
2318 | %{_bindir}/ceph_perf_local | |
2319 | %{_bindir}/ceph_perf_msgr_client | |
2320 | %{_bindir}/ceph_perf_msgr_server | |
2321 | %{_bindir}/ceph_psim | |
2322 | %{_bindir}/ceph_radosacl | |
2323 | %{_bindir}/ceph_rgw_jsonparser | |
2324 | %{_bindir}/ceph_rgw_multiparser | |
2325 | %{_bindir}/ceph_scratchtool | |
2326 | %{_bindir}/ceph_scratchtoolpp | |
7c673cae | 2327 | %{_bindir}/ceph_test_* |
7c673cae | 2328 | %{_bindir}/ceph-coverage |
7c673cae | 2329 | %{_bindir}/ceph-debugpack |
9f95a23c | 2330 | %{_bindir}/ceph-dedup-tool |
f67539c2 TL |
2331 | %if 0%{with seastar} |
2332 | %{_bindir}/crimson-store-nbd | |
2333 | %endif | |
7c673cae FG |
2334 | %{_mandir}/man8/ceph-debugpack.8* |
2335 | %dir %{_libdir}/ceph | |
2336 | %{_libdir}/ceph/ceph-monstore-update-crush.sh | |
2337 | %endif | |
2338 | ||
2339 | %if 0%{with cephfs_java} | |
2340 | %files -n libcephfs_jni1 | |
7c673cae FG |
2341 | %{_libdir}/libcephfs_jni.so.* |
2342 | ||
2343 | %post -n libcephfs_jni1 -p /sbin/ldconfig | |
2344 | ||
2345 | %postun -n libcephfs_jni1 -p /sbin/ldconfig | |
2346 | ||
2347 | %files -n libcephfs_jni-devel | |
7c673cae FG |
2348 | %{_libdir}/libcephfs_jni.so |
2349 | ||
2350 | %files -n cephfs-java | |
7c673cae FG |
2351 | %{_javadir}/libcephfs.jar |
2352 | %{_javadir}/libcephfs-test.jar | |
2353 | %endif | |
2354 | ||
2355 | %files -n rados-objclass-devel | |
7c673cae FG |
2356 | %dir %{_includedir}/rados |
2357 | %{_includedir}/rados/objclass.h | |
2358 | ||
2359 | %if 0%{with selinux} | |
2360 | %files selinux | |
7c673cae FG |
2361 | %attr(0600,root,root) %{_datadir}/selinux/packages/ceph.pp |
2362 | %{_datadir}/selinux/devel/include/contrib/ceph.if | |
2363 | %{_mandir}/man8/ceph_selinux.8* | |
2364 | ||
2365 | %post selinux | |
2366 | # backup file_contexts before update | |
2367 | . /etc/selinux/config | |
2368 | FILE_CONTEXT=/etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts | |
2369 | cp ${FILE_CONTEXT} ${FILE_CONTEXT}.pre | |
2370 | ||
2371 | # Install the policy | |
2372 | /usr/sbin/semodule -i %{_datadir}/selinux/packages/ceph.pp | |
2373 | ||
2374 | # Load the policy if SELinux is enabled | |
2375 | if ! /usr/sbin/selinuxenabled; then | |
2376 | # Do not relabel if selinux is not enabled | |
2377 | exit 0 | |
2378 | fi | |
2379 | ||
2380 | if diff ${FILE_CONTEXT} ${FILE_CONTEXT}.pre > /dev/null 2>&1; then | |
2381 | # Do not relabel if file contexts did not change | |
2382 | exit 0 | |
2383 | fi | |
2384 | ||
2385 | # Check whether the daemons are running | |
2386 | /usr/bin/systemctl status ceph.target > /dev/null 2>&1 | |
2387 | STATUS=$? | |
2388 | ||
2389 | # Stop the daemons if they were running | |
2390 | if test $STATUS -eq 0; then | |
2391 | /usr/bin/systemctl stop ceph.target > /dev/null 2>&1 | |
2392 | fi | |
2393 | ||
11fdf7f2 TL |
2394 | # Relabel the files fix for first package install |
2395 | /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null | |
31f18b77 | 2396 | |
7c673cae FG |
2397 | rm -f ${FILE_CONTEXT}.pre |
2398 | # The fixfiles command won't fix label for /var/run/ceph | |
2399 | /usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1 | |
2400 | ||
2401 | # Start the daemons iff they were running before | |
2402 | if test $STATUS -eq 0; then | |
2403 | /usr/bin/systemctl start ceph.target > /dev/null 2>&1 || : | |
2404 | fi | |
2405 | exit 0 | |
2406 | ||
2407 | %postun selinux | |
2408 | if [ $1 -eq 0 ]; then | |
2409 | # backup file_contexts before update | |
2410 | . /etc/selinux/config | |
2411 | FILE_CONTEXT=/etc/selinux/${SELINUXTYPE}/contexts/files/file_contexts | |
2412 | cp ${FILE_CONTEXT} ${FILE_CONTEXT}.pre | |
2413 | ||
2414 | # Remove the module | |
2415 | /usr/sbin/semodule -n -r ceph > /dev/null 2>&1 | |
2416 | ||
2417 | # Reload the policy if SELinux is enabled | |
2418 | if ! /usr/sbin/selinuxenabled ; then | |
2419 | # Do not relabel if SELinux is not enabled | |
2420 | exit 0 | |
2421 | fi | |
2422 | ||
2423 | # Check whether the daemons are running | |
2424 | /usr/bin/systemctl status ceph.target > /dev/null 2>&1 | |
2425 | STATUS=$? | |
2426 | ||
2427 | # Stop the daemons if they were running | |
2428 | if test $STATUS -eq 0; then | |
2429 | /usr/bin/systemctl stop ceph.target > /dev/null 2>&1 | |
2430 | fi | |
2431 | ||
2432 | /usr/sbin/fixfiles -C ${FILE_CONTEXT}.pre restore 2> /dev/null | |
2433 | rm -f ${FILE_CONTEXT}.pre | |
2434 | # The fixfiles command won't fix label for /var/run/ceph | |
2435 | /usr/sbin/restorecon -R /var/run/ceph > /dev/null 2>&1 | |
2436 | ||
2437 | # Start the daemons if they were running before | |
2438 | if test $STATUS -eq 0; then | |
2439 | /usr/bin/systemctl start ceph.target > /dev/null 2>&1 || : | |
2440 | fi | |
2441 | fi | |
2442 | exit 0 | |
1911f103 | 2443 | %endif |
7c673cae | 2444 | |
11fdf7f2 TL |
2445 | %files grafana-dashboards |
2446 | %if 0%{?suse_version} | |
81eedcae TL |
2447 | %attr(0755,root,root) %dir %{_sysconfdir}/grafana |
2448 | %attr(0755,root,root) %dir %{_sysconfdir}/grafana/dashboards | |
11fdf7f2 | 2449 | %endif |
801d1391 | 2450 | %attr(0755,root,root) %dir %{_sysconfdir}/grafana/dashboards/ceph-dashboard |
11fdf7f2 TL |
2451 | %config %{_sysconfdir}/grafana/dashboards/ceph-dashboard/* |
2452 | %doc monitoring/grafana/dashboards/README | |
2453 | %doc monitoring/grafana/README.md | |
7c673cae | 2454 | |
81eedcae | 2455 | %files prometheus-alerts |
801d1391 TL |
2456 | %if 0%{?suse_version} |
2457 | %attr(0755,root,root) %dir %{_sysconfdir}/prometheus | |
81eedcae | 2458 | %endif |
801d1391 TL |
2459 | %attr(0755,root,root) %dir %{_sysconfdir}/prometheus/ceph |
2460 | %config %{_sysconfdir}/prometheus/ceph/ceph_default_alerts.yml | |
7c673cae FG |
2461 | |
2462 | %changelog |