| Line 1... |
Line 1... |
| 1 |
#!/bin/bash
|
1 |
#!/bin/bash
|
| 2 |
# $Id: alcasar-urpmi.sh 1157 2013-07-16 10:48:11Z stephane $
|
2 |
# $Id: alcasar-urpmi.sh 1159 2013-07-17 09:25:15Z crox53 $
|
| 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 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"
|
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"
|
| 16 |
|
- |
|
| 17 |
rpm_repository_sync ()
|
16 |
rpm_repository_sync ()
|
| 18 |
{
|
17 |
{
|
| 19 |
cat <<EOF > /etc/urpmi/urpmi.cfg
|
18 |
cat <<EOF > /etc/urpmi/urpmi.cfg
|
| 20 |
{
|
19 |
{
|
| 21 |
downloader: wget
|
20 |
downloader: wget
|
| Line 226... |
Line 225... |
| 226 |
urpmi --no-verify --auto conf/rpms/$ARCH/*.rpm
|
225 |
urpmi --no-verify --auto conf/rpms/$ARCH/*.rpm
|
| 227 |
# restore chilli launch script
|
226 |
# restore chilli launch script
|
| 228 |
[ -e /tmp/chilli.conf ] && mv /tmp/chilli.conf /etc/
|
227 |
[ -e /tmp/chilli.conf ] && mv /tmp/chilli.conf /etc/
|
| 229 |
# Clean the RPM cache
|
228 |
# Clean the RPM cache
|
| 230 |
urpmi --clean
|
229 |
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 |
|
| 231 |
exit 0
|
246 |
exit 0
|