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