Subversion Repositories ALCASAR

Rev

Rev 1154 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 1154 Rev 1157
Line 1... Line 1...
1
#!/bin/bash
1
#!/bin/bash
2
# $Id: alcasar-urpmi.sh 1154 2013-07-15 14:27:10Z crox53 $
2
# $Id: alcasar-urpmi.sh 1157 2013-07-16 10:48:11Z stephane $
3
 
3
 
4
# alcasar-urpmi.sh
4
# alcasar-urpmi.sh
5
# by 3abtux and Rexy
5
# by 3abtux and Rexy
6
# This script is distributed under the Gnu General Public License (GPL)
6
# This script is distributed under the Gnu General Public License (GPL)
7
 
7
 
Line 10... Line 10...
10
 
10
 
11
Lang=`echo $LANG|cut -c 1-2`
11
Lang=`echo $LANG|cut -c 1-2`
12
VERSION="2"
12
VERSION="2"
13
ARCH="i586" 
13
ARCH="i586" 
14
# ****** Alcasar needed RPMS - paquetages nécessaires au fonctionnement d'Alcasar ******
14
# ****** Alcasar needed RPMS - paquetages nécessaires au fonctionnement d'Alcasar ******
15
PACKAGES="sudo freeradius freeradius-mysql freeradius-ldap freeradius-web apache-mpm-prefork apache-mod_ssl apache-mod_php iptables squid dansguardian postfix mariadb logwatch ntp bind-utils openssh-server php-xml php-ldap php-mysql pam_ccreds rng-utils dnsmasq syslinux rsync cronie-anacron clamav pm-fallback-policy php-mbstring perl-rrdtool perl-MailTools perl-Socket6 php-sockets kernel-desktop-3.4.45-1.mga2-1-1.mga2"
15
PACKAGES="sudo freeradius freeradius-mysql freeradius-ldap freeradius-web apache-mpm-prefork apache-mod_ssl apache-mod_php iptables squid dansguardian postfix mariadb logwatch ntp awstats bind-utils openssh-server php-xml php-ldap php-mysql pam_ccreds rng-utils dnsmasq syslinux rsync cronie-anacron clamav pm-fallback-policy php-mbstring"
-
 
16
 
16
rpm_repository_sync ()
17
rpm_repository_sync ()
17
{
18
{
18
cat <<EOF > /etc/urpmi/urpmi.cfg
19
cat <<EOF > /etc/urpmi/urpmi.cfg
19
{
20
{
20
downloader: wget
21
downloader: wget
Line 225... Line 226...
225
urpmi --no-verify --auto conf/rpms/$ARCH/*.rpm
226
urpmi --no-verify --auto conf/rpms/$ARCH/*.rpm
226
# restore chilli launch script
227
# restore chilli launch script
227
[ -e /tmp/chilli.conf ] && mv /tmp/chilli.conf /etc/
228
[ -e /tmp/chilli.conf ] && mv /tmp/chilli.conf /etc/
228
# Clean the RPM cache
229
# Clean the RPM cache
229
urpmi --clean
230
urpmi --clean
230
 
-
 
231
#Keep only kernel-desktop-3.4.45-1.mga2-1-1.mga2 version, and remove all others
-
 
232
kernelVersion=$(rpm -qa | grep "kernel-desktop")
-
 
233
for i in $kernelVersion
-
 
234
do
-
 
235
	if [ ! $i = "kernel-desktop-3.4.45-1.mga2-1-1.mga2" ];then
-
 
236
		urpme $i
-
 
237
	fi
-
 
238
done
-
 
239
 
-
 
240
#Fix the kernel version to : kernel-desktop-3.4.45-1.mga2-1-1.mga2
-
 
241
	echo "/^kernel-desktop/" > /etc/urpmi/skip.list 
-
 
242
 
-
 
243
#update tht kernel modules list
-
 
244
depmod -a
-
 
245
 
-
 
246
exit 0
231
exit 0