pandorafms/extras/anytermd/anytermd.redhat.spec
slerena 8594b9936c 012-05-05 Sancho Lerena <slerena@artica.es>
* anytermd: Added anyterm to extras. Included modifications on original
	anytermd project source code. Added a new spec file for centos/fedora/rhel.
	Tested on FC16/i386 and centos6/x86_84.




git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@6257 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
2012-05-04 19:14:27 +00:00

56 lines
1.4 KiB
RPMSpec

Name: anytermd
Version: 1.1.29
Release: 1.1.29
Summary: Pandora FMS Remote connection gateway
License: GPLv2
Group: Applications/Communications
Vendor: ArticaST <http://www.artica.es>
Source0: %{name}-%{version}.tar.gz
Packager: Sancho Lerena <slerena@artica.es>
BuildRoot: %{_tmppath}/%{name}-%{version}-buildroot
URL: http://pandorafms.org
Requires(post): /sbin/chkconfig
Requires(preun): /sbin/chkconfig
Requires(preun): /sbin/service
Requires(postun): /sbin/service
Requires: telnet openssh-clients
%description
Pandora FMS uses a tool called "anytermd" to create a "proxy" between user browser and remote destination. This tool launches as a daemon, listeting in a port, and executing a command, forwarding all output to the user browser. That means all the connections are done FROM the pandora server and it has to be installed the telnet and ssh client
%prep
rm -rf $RPM_BUILD_ROOT
%setup -q -n anytermd
%build
make
%install
install -Dm 755 contrib/anytermd $RPM_BUILD_ROOT%{_initrddir}/anytermd
install -Dm 755 anytermd $RPM_BUILD_ROOT%{_bindir}/anytermd
%clean
rm -rf $RPM_BUILD_ROOT
%post
if [ $1 -eq 0 ]; then
/sbin/chkconfig --add anytermd
fi
%preun
if [ $1 -eq 0 ]; then
/sbin/chkconfig --del anytermd
fi
%postun
if [ $1 -ge 1 ]; then
/sbin/service anytermd stop >/dev/null 2>&1
fi
%files
%defattr(-,root,root,-)
%{_bindir}/*
%{_initrddir}/anytermd