rpms/rubygem-mongrel_cluster/F-11 mongrel_cluster.init, NONE, 1.1 rubygem-mongrel_cluster.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Robert Scheck
robert at fedoraproject.org
Fri May 29 19:15:11 UTC 2009
- Previous message: rpms/rubygem-mongrel_cluster/F-10 mongrel_cluster.init, NONE, 1.1 rubygem-mongrel_cluster.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message: rpms/rubygem-mongrel_cluster/devel mongrel_cluster.init, NONE, 1.1 rubygem-mongrel_cluster.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: robert
Update of /cvs/pkgs/rpms/rubygem-mongrel_cluster/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv8959/F-11
Modified Files:
.cvsignore sources
Added Files:
mongrel_cluster.init rubygem-mongrel_cluster.spec
Log Message:
Initial import of rubygem-mongrel_cluster into Fedora and EPEL
--- NEW FILE mongrel_cluster.init ---
#!/bin/bash
#
# mongrel_cluster Startup script for mongrel clusters
#
# chkconfig: - 85 15
# description: The mongrel_cluster manages multiple mongrel processes \
# for the use behind a load balancer or a proxy server.
# processname: mongrel_rails
# config: /etc/mongrel_cluster/*.yml
# config: /etc/mongrel_cluster/*.conf
### BEGIN INIT INFO
# Provides: mongrel_cluster
# Required-Start: $local_fs $network $remote_fs $syslog
# Required-Stop: $local_fs $network $remote_fs $syslog
# Short-Description: Startup script for mongrel clusters
# Description: The mongrel_cluster manages multiple mongrel processes
# for the use behind a load balancer or a proxy server.
### END INIT INFO
# Source function library.
. /etc/rc.d/init.d/functions
# Paths to the scripts and files
mongrel="/usr/bin/mongrel_rails"
prog="mongrel_cluster"
configdir="/etc/mongrel_cluster"
lockfile="/var/lock/subsys/mongrel_cluster"
RETVAL=0
# See how we were called.
case "$1" in
start)
if [ $# -gt 1 ]; then
shift 1
configs="$@"
else
configs="$configdir/*.yml $configdir/*.conf"
fi
for config in $configs; do
if [ "`basename $config`" = "$config" ]; then
config="$configdir/$config"
fi
if [ -f $config ]; then
file=`basename $config`
echo -n $"Starting $prog for $file: "
$mongrel cluster::start -C $config >> /dev/null 2&>1i
RETVAL=$?
[ $RETVAL -eq 0 ] && echo_success || echo_failure
echo
fi
done
[ $RETVAL -eq 0 ] && touch $lockfile
;;
stop)
if [ $# -gt 1 ]; then
shift 1
configs="$@"
else
configs="$configdir/*.yml $configdir/*.conf"
fi
for config in $configs; do
if [ "`basename $config`" = "$config" ]; then
config="$configdir/$config"
fi
if [ -f $config ]; then
file=`basename $config`
echo -n $"Stopping $prog for $file: "
$mongrel cluster::stop -C $config >> /dev/null 2&>1i
RETVAL=$?
[ $RETVAL -eq 0 ] && echo_success || echo_failure
echo
fi
done
[ $RETVAL -eq 0 ] && rm -f $lockfile
;;
status)
if [ $# -gt 1 ]; then
shift 1
configs="$@"
else
configs="$configdir/*.yml $configdir/*.conf"
fi
for config in $configs; do
if [ "`basename $config`" = "$config" ]; then
config="$configdir/$config"
fi
if [ -f $config ]; then
file=`basename $config`
echo $0 status $file
$mongrel cluster::status -C $config 2> /dev/null
fi
done
;;
restart|reload|force-reload)
if [ $# -gt 1 ]; then
shift 1
configs="$@"
else
configs="$configdir/*.yml $configdir/*.conf"
fi
for config in $configs; do
if [ "`basename $config`" = "$config" ]; then
config="$configdir/$config"
fi
if [ -f $config ]; then
file=`basename $config`
echo -n $"Restarting $prog for $file: "
$mongrel cluster::restart -C $config >> /dev/null 2&>1i
RETVAL=$?
[ $RETVAL -eq 0 ] && echo_success || echo_failure
echo
fi
done
[ $RETVAL -eq 0 ] && touch $lockfile
;;
condrestart|try-restart)
if [ -f $lockfile ]; then
shift 1
$0 stop $@
$0 start $@
fi
;;
*)
echo $"Usage: $prog {start|stop|status|reload|restart|condrestart|force-reload|try-restart} [<configfile.{yml|conf}>]"
RETVAL=1
esac
exit $RETVAL
--- NEW FILE rubygem-mongrel_cluster.spec ---
%define gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
%define gemname mongrel_cluster
%define geminstdir %{gemdir}/gems/%{gemname}-%{version}
%define ruby_sitelib %(ruby -rrbconfig -e "puts Config::CONFIG['sitelibdir']")
%define ruby_abiver %((echo "1.8"; ruby -rrbconfig -e "puts Config::CONFIG['ruby_version']" 2>/dev/null) | tail -1)
Summary: GemPlugin wrapper for the mongrel HTTP server
Name: rubygem-%{gemname}
Version: 1.0.5
Release: 2%{?dist}
License: GPLv2 or Ruby
Group: System Environment/Daemons
URL: http://mongrel.rubyforge.org/wiki/MongrelCluster
Source0: http://gems.rubyforge.org/gems/%{gemname}-%{version}.gem
Source1: mongrel_cluster.init
%if 0%{?rhel}%{?fedora} > 5
Requires: ruby(abi) = %{ruby_abiver}
%endif
Requires: rubygems, rubygem(mongrel) >= 1.0.0
Requires(post): /sbin/chkconfig
Requires(preun): /sbin/service, /sbin/chkconfig
Requires(postun): /sbin/service
Provides: rubygem(%{gemname}) = %{version}
BuildRequires: rubygems
BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
Mongrel_cluster is a GemPlugin that wrappers the mongrel HTTP server and
simplifies the deployment of webapps using a cluster of mongrel servers.
Mongrel_cluster will conveniently configure and control several mongrel
servers or groups of mongrel servers, which are then load balanced using
a reverse proxy solution.
%prep
%build
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{gemdir}
gem install --local --install-dir $RPM_BUILD_ROOT%{gemdir} --force --rdoc %{SOURCE0}
find $RPM_BUILD_ROOT -type f | xargs -n 1 sed -i -e 's@^#!/usr/bin/env ruby@#!/usr/bin/ruby@'
rm -f $RPM_BUILD_ROOT%{geminstdir}/{Manifest,mongrel_cluster.gemspec}
rm -f $RPM_BUILD_ROOT%{gemdir}/bin/mongrel_cluster_ctl
rm -f $RPM_BUILD_ROOT%{geminstdir}/resources/%{gemname}
# Copy the initscript to its appropriate place
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/{rc.d/init.d,%{gemname}}
install -p -m 755 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/%{gemname}
# Move the mongrel_cluster_ctl to correct place
mkdir -p $RPM_BUILD_ROOT%{_bindir}
mv -f $RPM_BUILD_ROOT%{geminstdir}/bin/mongrel_cluster_ctl $RPM_BUILD_ROOT%{_bindir}
%post
/sbin/chkconfig --add %{gemname}
%preun
if [ $1 -eq 0 ]; then
/sbin/service %{gemname} stop > /dev/null 2>&1 || :
/sbin/chkconfig --del %{gemname}
fi
%postun
if [ $1 -ne 0 ]; then
/sbin/service %{gemname} condrestart > /dev/null 2>&1 || :
fi
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc %{geminstdir}/CHANGELOG
%doc %{geminstdir}/COPYING
%doc %{geminstdir}/LICENSE
%doc %{geminstdir}/README
%{_bindir}/mongrel_cluster_ctl
%{_sysconfdir}/rc.d/init.d/%{gemname}
%dir %{_sysconfdir}/%{gemname}
%dir %{geminstdir}
%{geminstdir}/lib
%{geminstdir}/resources
%{gemdir}/cache/%{gemname}-%{version}.gem
%{gemdir}/specifications/%{gemname}-%{version}.gemspec
%changelog
* Tue May 26 2009 Robert Scheck <robert at fedoraproject.org> 1.0.5-2
- Added missing requirement to ruby(abi) = version (#501134 #c1)
- Rewrote initscript to support single clusters and reload/subsys
* Sat May 16 2009 Robert Scheck <robert at fedoraproject.org> 1.0.5-1
- Upgrade to 1.0.5
* Mon Jul 21 2008 Robert Scheck <robert at fedoraproject.org> 1.0.4-1
- Upgrade to 1.0.4
- Initial spec file for Fedora and Red Hat Enterprise Linux
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/rubygem-mongrel_cluster/F-11/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- .cvsignore 29 May 2009 15:32:43 -0000 1.1
+++ .cvsignore 29 May 2009 19:14:41 -0000 1.2
@@ -0,0 +1 @@
+mongrel_cluster-1.0.5.gem
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/rubygem-mongrel_cluster/F-11/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- sources 29 May 2009 15:32:43 -0000 1.1
+++ sources 29 May 2009 19:14:41 -0000 1.2
@@ -0,0 +1 @@
+7ff77538842c97b363137c471903f7e3 mongrel_cluster-1.0.5.gem
- Previous message: rpms/rubygem-mongrel_cluster/F-10 mongrel_cluster.init, NONE, 1.1 rubygem-mongrel_cluster.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message: rpms/rubygem-mongrel_cluster/devel mongrel_cluster.init, NONE, 1.1 rubygem-mongrel_cluster.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the scm-commits
mailing list