automatic version update by autodist [release 1.590-1mamba;Tue Mar 18 2014]
This commit is contained in:
parent
5a80db8ea2
commit
8257aac107
@ -1,2 +1,4 @@
|
|||||||
# usermin
|
# usermin
|
||||||
|
|
||||||
|
Usermin is a web-based interface for webmail, password changing, mail filters, fetchmail and much more. It is designed for use by regular non-root users on a Unix system, and limits them to tasks that they would be able to perform if logged in via SSH or at the console. See the standard modules page for a list of all the functions built into Usermin.
|
||||||
|
|
||||||
|
57
usermin-1.400-install_noroot.patch
Normal file
57
usermin-1.400-install_noroot.patch
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
diff -Nru usermin-1.400/setup.sh usermin-1.400.patch/setup.sh
|
||||||
|
--- usermin-1.400/setup.sh 2009-03-18 06:34:22.000000000 +0100
|
||||||
|
+++ usermin-1.400.patch/setup.sh 2009-04-30 18:46:35.000000000 +0200
|
||||||
|
@@ -33,17 +33,6 @@
|
||||||
|
echo "systems and common Unix services to be easily administered."
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
-# Only root can run this
|
||||||
|
-id | grep "uid=0(" >/dev/null
|
||||||
|
-if [ $? != "0" ]; then
|
||||||
|
- uname -a | grep -i CYGWIN >/dev/null
|
||||||
|
- if [ $? != "0" ]; then
|
||||||
|
- echo "ERROR: The Usermin install script must be run as root";
|
||||||
|
- echo "";
|
||||||
|
- exit 1;
|
||||||
|
- fi
|
||||||
|
-fi
|
||||||
|
-
|
||||||
|
# Use the supplied destination directory, if any
|
||||||
|
if [ "$1" != "" ]; then
|
||||||
|
wadir=$1
|
||||||
|
@@ -345,12 +334,6 @@
|
||||||
|
echo ""
|
||||||
|
exit 12
|
||||||
|
fi
|
||||||
|
- $perl -e 'use Socket; socket(FOO, PF_INET, SOCK_STREAM, getprotobyname("tcp")); setsockopt(FOO, SOL_SOCKET, SO_REUSEADDR, pack("l", 1)); bind(FOO, pack_sockaddr_in($ARGV[0], INADDR_ANY)) || exit(1); exit(0);' $port
|
||||||
|
- if [ $? != "0" ]; then
|
||||||
|
- echo "ERROR: TCP port $port is already in use by another program"
|
||||||
|
- echo ""
|
||||||
|
- exit 13
|
||||||
|
- fi
|
||||||
|
|
||||||
|
# Ask the user if SSL should be used
|
||||||
|
if [ "$ssl" = "" ]; then
|
||||||
|
@@ -621,22 +604,6 @@
|
||||||
|
echo ""
|
||||||
|
fi
|
||||||
|
|
||||||
|
-echo "Changing ownership and permissions .."
|
||||||
|
-chown -R root:bin $config_dir
|
||||||
|
-chmod -R 755 $config_dir
|
||||||
|
-if [ "$nochown" = "" ]; then
|
||||||
|
- chown -R root:bin "$wadir"
|
||||||
|
- chmod -R og-w "$wadir"
|
||||||
|
- if [ $var_dir != "/var" ]; then
|
||||||
|
- chown -R root:bin $var_dir
|
||||||
|
- chmod -R og-w $var_dir
|
||||||
|
- chmod -R a+rx "$wadir"
|
||||||
|
- fi
|
||||||
|
-fi
|
||||||
|
-chmod 600 $config_dir/miniserv.pem 2>/dev/null
|
||||||
|
-echo "..done"
|
||||||
|
-echo ""
|
||||||
|
-
|
||||||
|
# Save target directory if one was specified
|
||||||
|
if [ "$wadir" != "$srcdir" ]; then
|
||||||
|
echo $wadir >$config_dir/install-dir
|
14
usermin-1.400-openmamba.patch
Normal file
14
usermin-1.400-openmamba.patch
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
diff -Nru usermin-1.400.orig/config-openmamba-linux usermin-1.400/config-openmamba-linux
|
||||||
|
--- usermin-1.400.orig/config-openmamba-linux 1970-01-01 01:00:00.000000000 +0100
|
||||||
|
+++ usermin-1.400/config-openmamba-linux 2009-04-30 18:44:18.000000000 +0200
|
||||||
|
@@ -0,0 +1,10 @@
|
||||||
|
+find_pid_command=ps auwwwx | grep NAME | grep -v grep | awk '{ print $2 }'
|
||||||
|
+path=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
|
||||||
|
+ld_env=LD_LIBRARY_PATH
|
||||||
|
+passwd_file=/etc/shadow
|
||||||
|
+passwd_uindex=0
|
||||||
|
+passwd_pindex=1
|
||||||
|
+passwd_cindex=2
|
||||||
|
+passwd_mindex=4
|
||||||
|
+by_view=0
|
||||||
|
+tempdelete_days=7
|
13
usermin-desktop
Normal file
13
usermin-desktop
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Version=1.0
|
||||||
|
Encoding=UTF-8
|
||||||
|
Name=Webmin
|
||||||
|
GenericName=Web based interface for user services
|
||||||
|
GenericName[it]=Interfaccia web per servizi dell'utente
|
||||||
|
Comment=Webmail, password changing, mail filters, fetchmail and much more
|
||||||
|
Comment[it]=Webmail, cambio password, filtri email, fetchmail e altro
|
||||||
|
Exec=konqueror https://localhost:20000
|
||||||
|
Type=Application
|
||||||
|
Icon=kcontrol
|
||||||
|
Terminal=false
|
||||||
|
Categories=Application;System;
|
51
usermin-initscript
Normal file
51
usermin-initscript
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
#! /bin/bash
|
||||||
|
#
|
||||||
|
# webmin Start/Stop the usermin service
|
||||||
|
# Copyright (c) 2009 by Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||||
|
#
|
||||||
|
# chkconfig: 2345 90 60
|
||||||
|
# description: a web-based interface for usermin
|
||||||
|
#
|
||||||
|
# Source function library.
|
||||||
|
. /etc/init.d/functions
|
||||||
|
|
||||||
|
USERMIN_CONFIG=/etc/usermin
|
||||||
|
RETVAL=0
|
||||||
|
|
||||||
|
prog="webmin"
|
||||||
|
|
||||||
|
start() {
|
||||||
|
echo -n $"Starting $prog: "
|
||||||
|
$USERMIN_CONFIG/start
|
||||||
|
evaluate_retval
|
||||||
|
echo
|
||||||
|
}
|
||||||
|
|
||||||
|
stop() {
|
||||||
|
echo -n $"Stopping $prog: "
|
||||||
|
$USERMIN_CONFIG/stop
|
||||||
|
evaluate_retval
|
||||||
|
echo
|
||||||
|
}
|
||||||
|
|
||||||
|
restart() {
|
||||||
|
stop
|
||||||
|
start
|
||||||
|
}
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
start)
|
||||||
|
start
|
||||||
|
;;
|
||||||
|
stop)
|
||||||
|
stop
|
||||||
|
;;
|
||||||
|
restart)
|
||||||
|
restart
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
echo $"Usage: $0 {start|stop|restart}"
|
||||||
|
exit 1
|
||||||
|
esac
|
||||||
|
|
||||||
|
exit $?
|
170
usermin.spec
Normal file
170
usermin.spec
Normal file
@ -0,0 +1,170 @@
|
|||||||
|
Name: usermin
|
||||||
|
Version: 1.590
|
||||||
|
Release: 1mamba
|
||||||
|
Summary: A web-based interface for webmail, password changing, mail filters, fetchmail and much more
|
||||||
|
Group: Applications/Web
|
||||||
|
Vendor: openmamba
|
||||||
|
Distribution: openmamba
|
||||||
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
||||||
|
URL: http://www.webmin.com/usermin.html
|
||||||
|
Source: http://downloads.sourceforge.net/sourceforge/webadmin/usermin-%{version}.tar.gz
|
||||||
|
Source1: usermin-initscript
|
||||||
|
Source2: usermin-desktop
|
||||||
|
Patch0: %{name}-1.400-install_noroot.patch
|
||||||
|
Patch1: %{name}-1.400-openmamba.patch
|
||||||
|
License: GPL
|
||||||
|
Requires: perl-Authen-PAM
|
||||||
|
Requires: lsof
|
||||||
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
||||||
|
|
||||||
|
%description
|
||||||
|
Usermin is a web-based interface for webmail, password changing, mail filters, fetchmail and much more. It is designed for use by regular non-root users on a Unix system, and limits them to tasks that they would be able to perform if logged in via SSH or at the console. See the standard modules page for a list of all the functions built into Usermin.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q
|
||||||
|
%patch0 -p1
|
||||||
|
#%patch1 -p1
|
||||||
|
|
||||||
|
find . -type f -exec sed -i 's|/usr/local/bin/perl|/usr/bin/perl|g' {} \;
|
||||||
|
|
||||||
|
%define _use_internal_dependency_generator 0
|
||||||
|
%define __find_provides %{_builddir}/usermin-%{version}/find_provides.sh
|
||||||
|
cat > %{_builddir}/usermin-%{version}/find_provides.sh <<_EOF
|
||||||
|
#! /bin/sh
|
||||||
|
%{_prefix}/lib/rpm/find-provides %{buildroot} %{_target_cpu} | \
|
||||||
|
grep -v "perl(.::" | grep -v "perl(..::" | grep -v "perl()"
|
||||||
|
_EOF
|
||||||
|
chmod +x %{_builddir}/usermin-%{version}/find_provides.sh
|
||||||
|
|
||||||
|
%define __find_requires %{_builddir}/usermin-%{version}/find_requires.sh
|
||||||
|
cat > %{_builddir}/usermin-%{version}/find_requires.sh <<_EOF
|
||||||
|
#! /bin/sh
|
||||||
|
%{_prefix}/lib/rpm/find-requires %{buildroot} %{_target_cpu} | \
|
||||||
|
grep -v "perl(.::" | grep -v "perl(..::" | grep -v "perl()"
|
||||||
|
_EOF
|
||||||
|
chmod +x %{_builddir}/usermin-%{version}/find_requires.sh
|
||||||
|
|
||||||
|
%build
|
||||||
|
|
||||||
|
%install
|
||||||
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||||
|
install -d %{buildroot}{%{_sysconfdir}/usermin,%{_prefix},/var/log/usermin,/opt/usermin}
|
||||||
|
|
||||||
|
config_dir=%{buildroot}%{_sysconfdir}/usermin \
|
||||||
|
var_dir=%{buildroot}/var/log/usermin \
|
||||||
|
perl=%{_bindir}/perl \
|
||||||
|
port=20000 \
|
||||||
|
login=admin \
|
||||||
|
password=tmppass \
|
||||||
|
ssl=1 \
|
||||||
|
atboot=0 \
|
||||||
|
nostart=1 \
|
||||||
|
tempdir=. \
|
||||||
|
./setup.sh %{buildroot}/opt/usermin
|
||||||
|
|
||||||
|
rm -f %{buildroot}%{_sysconfdir}/usermin/uninstall.sh
|
||||||
|
|
||||||
|
# strip buildroot from configuration files
|
||||||
|
find %{buildroot}%{_sysconfdir}/usermin -type f -exec sed -i 's|%{buildroot}||g' {} \;
|
||||||
|
|
||||||
|
# install initscript
|
||||||
|
install -D -m 0755 %{SOURCE1} %{buildroot}%{_initrddir}/usermin
|
||||||
|
|
||||||
|
# install desktop link
|
||||||
|
install -D -m 0644 %{SOURCE2} %{buildroot}%{_datadir}/applications/usermin.desktop
|
||||||
|
|
||||||
|
# install pam file
|
||||||
|
install -D -m 0644 usermin-pam %{buildroot}%{_sysconfdir}/pam.d/usermin
|
||||||
|
|
||||||
|
mkdir -p %{buildroot}/var/log/usermin
|
||||||
|
|
||||||
|
%clean
|
||||||
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
||||||
|
|
||||||
|
%post
|
||||||
|
# new install
|
||||||
|
if [ $1 -eq 1 ]; then
|
||||||
|
/sbin/chkconfig --add usermin
|
||||||
|
service usermin start
|
||||||
|
fi
|
||||||
|
if [ $1 -gt 1 ]; then
|
||||||
|
# upgrade
|
||||||
|
service usermin restart
|
||||||
|
fi
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
|
||||||
|
%preun
|
||||||
|
#erase
|
||||||
|
if [ $1 -eq 0 ]; then
|
||||||
|
service usermin stop 2>/dev/null
|
||||||
|
/sbin/chkconfig --del usermin
|
||||||
|
fi
|
||||||
|
exit 0
|
||||||
|
|
||||||
|
%files
|
||||||
|
%defattr(-,root,root)
|
||||||
|
%{_initrddir}/usermin
|
||||||
|
%dir %{_sysconfdir}/usermin
|
||||||
|
%config(noreplace) %{_sysconfdir}/usermin/*
|
||||||
|
%{_sysconfdir}/pam.d/usermin
|
||||||
|
%{_datadir}/applications/usermin.desktop
|
||||||
|
%dir /opt/usermin
|
||||||
|
/opt/usermin/*
|
||||||
|
%dir /var/log/usermin
|
||||||
|
%doc LICENCE README
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Tue Mar 18 2014 Automatic Build System <autodist@mambasoft.it> 1.590-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Thu Feb 06 2014 Automatic Build System <autodist@mambasoft.it> 1.570-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Tue Aug 20 2013 Automatic Build System <autodist@mambasoft.it> 1.560-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Fri May 17 2013 Automatic Build System <autodist@mambasoft.it> 1.550-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Mon Feb 25 2013 Automatic Build System <autodist@mambasoft.it> 1.540-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Sun Nov 25 2012 Automatic Build System <autodist@mambasoft.it> 1.530-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Fri Oct 12 2012 Automatic Build System <autodist@mambasoft.it> 1.520-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Sat Aug 11 2012 Automatic Build System <autodist@mambasoft.it> 1.510-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Wed May 02 2012 Automatic Build System <autodist@mambasoft.it> 1.500-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Wed Aug 10 2011 Automatic Build System <autodist@mambasoft.it> 1.480-1mamba
|
||||||
|
- automatic version update by autodist
|
||||||
|
|
||||||
|
* Fri Apr 15 2011 Automatic Build System <autodist@mambasoft.it> 1.470-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Mon Dec 06 2010 Automatic Build System <autodist@mambasoft.it> 1.460-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Mon Oct 04 2010 Automatic Build System <autodist@mambasoft.it> 1.450-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Fri Apr 09 2010 Silvan Calarco <silvan.calarco@mambasoft.it> 1.440-1mamba
|
||||||
|
- update to 1.440
|
||||||
|
|
||||||
|
* Tue Dec 08 2009 Automatic Build System <autodist@mambasoft.it> 1.430-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Wed Sep 23 2009 Automatic Build System <autodist@mambasoft.it> 1.420-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Mon Jun 22 2009 Automatic Build System <autodist@mambasoft.it> 1.410-1mamba
|
||||||
|
- automatic update by autodist
|
||||||
|
|
||||||
|
* Thu Apr 30 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 1.400-1mamba
|
||||||
|
- package created by autospec
|
Loading…
Reference in New Issue
Block a user