]> git.pld-linux.org Git - packages/heartbeat.git/blob - heartbeat.spec
- massive attack: source-md5
[packages/heartbeat.git] / heartbeat.spec
1 Summary:        Heartbeat - subsystem for High-Availability Linux
2 Summary(es):    Subsistema heartbeat para Linux "High-Availability"
3 Summary(pl):    Podsystem heartbeat dla systemów o podwy¿szonej niezawodno¶ci
4 Summary(pt_BR): Implementa sistema de monitoração (heartbeats) visando Alta Disponibilidade
5 Name:           heartbeat
6 Version:        0.4.9.1
7 Release:        0.9
8 License:        GPL v2+
9 Group:          Applications/System
10 Source0:        http://linux-ha.org/download/%{name}-%{version}.tar.gz
11 # Source0-md5:  55dad02995b04a7122c51ca1b15738e3
12 Patch0:         %{name}.dirty.time.h.patch
13 Patch1:         %{name}-remove_groupadd_and_chgrp.patch
14 Patch2:         %{name}-manpath.patch
15 Patch3:         %{name}-doc_fix.patch
16 Patch4:         %{name}-install_stupidity.patch
17 # SuSE-specific; transformation unfinished
18 Patch5:         %{name}-init.patch
19 URL:            http://linux-ha.org/
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21 BuildRequires:  links
22 Requires(pre):  /sbin/chkconfig
23 Requires(pre): /usr/bin/getgid
24 Requires(pre): /usr/sbin/groupadd
25 Requires(post):        /usr/sbin/groupdel
26 Requires:       syslogdaemon
27
28 %description
29 heartbeat is a basic heartbeat subsystem for Linux-HA. It will run
30 scripts at initialization, and when machines go up or down. This
31 version will also perform IP address takeover using gratuitous ARPs.
32 It works correctly for a 2-node configuration, and is extensible to
33 larger configurations.
34
35 It implements the following kinds of heartbeats:
36  - Bidirectional Serial Rings ("raw" serial ports)
37
38 %description -l es
39 heartbeat es un sistema básico para Linux-HA. La función de este
40 software es ejecutar scripts en la inicialización y al apagar las
41 máquinas que lo utilizan.
42
43 %description -l pl
44 heartbeat jest podstawowym podsystemem dla systemów o podwy¿szonej
45 dostêpno¶ci budowanych w oparciu o Linuksa. Zajmuje siê uruchamianiem
46 skryptów podczas startu i zamykania systemu. Ta wersja pakietu pozwala
47 na przejmowanie adresów IP. Oprogramowanie dzia³a poprawnie dla
48 konfiguracji sk³adaj±cej siê z 2 hostów, mo¿na je równie¿ stosowaæ do
49 bardziej skomplikowanych konfiguracji.
50
51 #%package stonith
52 #Summary: Provides an interface to Shoot The Other Node In The Head
53 #Group: Utilities
54
55 %prep
56 %setup -q
57 %patch0 -p0
58 %patch1 -p0
59 %patch2 -p0
60 %patch3 -p1
61 %patch4 -p1
62 %patch5 -p0
63
64 %build
65 #zmienic to:
66 sed -e 's/MAKE=gmake/MAKE=make/g' < Makefile > aqq
67 mv -f aqq Makefile
68 cd doc
69 sed -e 's/lynx/links/' > aqq < Makefile
70 mv -f aqq Makefile
71 cd ..
72 %{__make}
73
74 %install
75 rm -rf $RPM_BUILD_ROOT
76 RPM_BUILD=yes BUILD_ROOT=$RPM_BUILD_ROOT %{__make} install
77
78 rm -f $RPM_BUILD_ROOT%{_sysconfdir}/ha.d/resource.d/ldirectord
79 ln -sf %{_sbindir}/ldirectord $RPM_BUILD_ROOT%{_sysconfdir}/ha.d/resource.d/ldirectord
80
81 TEMPL=$RPM_BUILD_ROOT/var/adm/fillup-templates
82 if [ ! -d $TEMPL ]; then
83         install -d $TEMPL
84 fi
85 install rc.config.heartbeat $TEMPL
86
87 rm -f doc/{*.html,*.8,COPYING,Makefile*}
88
89
90 %clean
91 rm -rf $RPM_BUILD_ROOT
92
93 %pre
94 if [ -n "`/usr/bin/getgid haclient`" ]; then
95        if [ "`/usr/bin/getgid haclient`" != "60" ]; then
96                echo "Error: group haclient doesn't have gid=60. Correct this before installing heartbeat." 1>&2
97                exit 1
98        fi
99 else
100        /usr/sbin/groupadd -g 60 -r haclient
101 fi
102
103 %post
104 /sbin/chkconfig --add heartbeat
105
106 %preun
107 Uninstall_PPP_hack() {
108   file2hack=etc/ppp/ip-up.local
109   echo "NOTE: Restoring /$file2hack"
110   MARKER="Heartbeat"
111   ed -s $file2hack <<-!EOF  2>/dev/null
112 H
113 g/ $MARKER\$/d
114 w
115 !EOF
116 }
117
118 if [ "$1" = "0" ]; then
119         /sbin/chkconfig --del heartbeat
120         if [ ! -x etc/ppp/ip-up.heart ]; then
121                 Uninstall_PPP_hack
122         fi
123 fi
124
125 %postun
126 if [ "$1" = "0" ]; then
127        /usr/sbin/groupdel haclient 2>/dev/null
128 fi
129
130 %files
131 %defattr(644,root,root,755)
132 %doc doc/*
133 %attr (755,root,root) %{_sysconfdir}/ha.d/harc
134 %attr (755,root,root) %{_sbindir}/*
135 %{_sysconfdir}/ha.d/shellfuncs
136 %{_sysconfdir}/ha.d/rc.d
137 %{_sysconfdir}/ha.d/README.config
138 %{_sysconfdir}/ha.d/conf
139 %{_sysconfdir}/ha.d/resource.d/
140 %dir %{_sysconfdir}/ha.d
141 /etc/rc.d/init.d/*
142 /etc/logrotate.d/*
143
144 # this is probably not the best location for binaries...
145 %{_libdir}/heartbeat
146 #%%{_libdir}/libhbclient.so
147 #%%{_libdir}/libhbclient.a
148 %{_libdir}/*.so
149 %{_libdir}/*.a
150 %dir %{_libdir}/stonith
151 %{_libdir}/stonith/*.so
152 /var/adm/fillup-templates/rc.config.heartbeat
153 %dir /var/lib/heartbeat
154 %attr (600,root,root) /var/lib/heartbeat/fifo
155 %attr (750,root,haclient) /var/lib/heartbeat/api
156 %attr (620,root,haclient) /var/lib/heartbeat/register
157 %attr (1770,root,haclient) /var/lib/heartbeat/casual
158 %{_mandir}/man8/*.8*
This page took 0.063389 seconds and 4 git commands to generate.