Subversion Repositories ALCASAR

Rev

Rev 3104 | Rev 3114 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 3104 Rev 3111
Line 23... Line 23...
23
# "postfix" + "cyrus-sasl" + "lib64sasl2-plug-plain" : email registration method
23
# "postfix" + "cyrus-sasl" + "lib64sasl2-plug-plain" : email registration method
24
PACKAGES="vim-enhanced freeradius freeradius-mysql freeradius-ldap lighttpd lighttpd-mod_auth php-fpm php-gd php-ldap php-mysqli php-mbstring php-sockets php-curl php-pdo_sqlite php-cli php-dom unbound e2guardian postfix mariadb ntp bind-utils openssh-server rng-utils rsync clamav clamav-db clamd fail2ban gnupg2 ulogd ipset usb_modeswitch vnstat dos2unix p7zip msec kernel-userspace-headers kernel-firmware kernel-firmware-nonfree dhcp-server tcpdump fonts-dejavu-common fonts-ttf-dejavu lsscsi nvme-cli sudo socat postfix cyrus-sasl lib64sasl2-plug-plain iftop"
24
PACKAGES="vim-enhanced freeradius freeradius-mysql freeradius-ldap lighttpd lighttpd-mod_auth php-fpm php-gd php-ldap php-mysqli php-mbstring php-sockets php-curl php-pdo_sqlite php-cli php-dom unbound e2guardian postfix mariadb ntp bind-utils openssh-server rng-utils rsync clamav clamav-db clamd fail2ban gnupg2 ulogd ipset usb_modeswitch vnstat dos2unix p7zip msec kernel-userspace-headers kernel-firmware kernel-firmware-nonfree dhcp-server tcpdump fonts-dejavu-common fonts-ttf-dejavu lsscsi nvme-cli sudo socat postfix cyrus-sasl lib64sasl2-plug-plain iftop"
25
 
25
 
26
rpm_repository_sync ()
26
rpm_repository_sync ()
27
{
27
{
28
cat <<EOF > /etc/urpmi/urpmi.cfg
28
	cat <<EOF > /etc/urpmi/urpmi.cfg
29
{
29
{
30
downloader: wget
30
downloader: wget
31
}
31
}
32
EOF
32
EOF
33
echo ${!MIRRORLIST}
33
	echo ${!MIRRORLIST}
34
urpmi.addmedia core --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/core/release
34
	urpmi.addmedia core --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/core/release
35
urpmi.addmedia core-updates --update --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/core/updates
35
	urpmi.addmedia core-updates --update --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/core/updates
36
urpmi.addmedia nonfree --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/nonfree/release
36
	urpmi.addmedia nonfree --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/nonfree/release
37
urpmi.addmedia nonfree-updates --update --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/nonfree/updates
37
	urpmi.addmedia nonfree-updates --update --probe-synthesis --mirrorlist ${!MIRRORLIST} /media/nonfree/updates
38
}
38
}
39
 
39
 
40
rpm_error ()
40
rpm_error ()
41
{
41
{
-
 
42
	# restore previous rpm conf file & removed RPMs
-
 
43
	[ -e /etc/urpmi/urpmi.cfg.old ] && mv /etc/urpmi/urpmi.cfg.old /etc/urpmi/urpmi.cfg
-
 
44
	urpmi --no-verify-rpm --auto rpms/$ARCH/wkhtmltopdf*.rpm
-
 
45
	urpmi --auto --quiet freeradius-ldap lighttpd-mod_auth
42
echo
46
	echo
43
if [ $Lang == "fr" ]
47
	if [ $Lang == "fr" ]
44
then
48
	then
45
	echo "Relancez l'installation ultérieurement."
49
		echo "Relancez l'installation ultérieurement."
46
	echo "Si vous rencontrez à nouveau ce problème, modifier les variables MIRRORLIST[1&2] du fichier 'scripts/alcasar-rpm.sh'"
50
		echo "Si vous rencontrez à nouveau ce problème, modifier les variables MIRRORLIST[1&2] du fichier 'scripts/alcasar-rpm.sh'"
47
else
51
	else
48
	echo "Try an other install later."
52
		echo "Try an other install later."
49
	echo "If this problem occurs again, change the MIRRORLIST[1&2] variables in the file 'scripts/alcasar-rpm.sh'"
53
		echo "If this problem occurs again, change the MIRRORLIST[1&2] variables in the file 'scripts/alcasar-rpm.sh'"
50
fi
54
	fi
51
}
55
}
52
 
56
 
53
# extract the current Mageia version and hardware architecture (i586 ou X64)
57
# extract the current Mageia version and hardware architecture (i586 ou X64)
54
fic=`cat /etc/product.id`
58
fic=`cat /etc/product.id`
55
old="$IFS"
59
old="$IFS"
Line 74... Line 78...
74
 
78
 
75
# We prefer wget than curl
79
# We prefer wget than curl
76
urpmi --no-verify-rpm --auto rpms/$ARCH/wget*.rpm
80
urpmi --no-verify-rpm --auto rpms/$ARCH/wget*.rpm
77
 
81
 
78
# Set the RPM repository (if not already set)
82
# Set the RPM repository (if not already set)
-
 
83
cp /etc/urpmi/urpmi.cfg /etc/urpmi/urpmi.cfg.old
79
ACTIVE_REPO=`cat /etc/urpmi/urpmi.cfg|grep "mageia.org"|wc -l`
84
ACTIVE_REPO=`cat /etc/urpmi/urpmi.cfg|grep "mageia.org"|wc -l`
80
MIRROR_NBR=3
85
MIRROR_NBR=3
81
#                       For French
86
#                       For French
82
MIRRORLIST1="http://ftp.free.fr/mirrors/mageia.org/distrib/$VERSION/$ARCH"
87
MIRRORLIST1="http://ftp.free.fr/mirrors/mageia.org/distrib/$VERSION/$ARCH"
83
#                       For Europeans
88
#                       For Europeans
Line 116... Line 121...
116
		do
121
		do
117
			read response
122
			read response
118
		done
123
		done
119
		if [ "$response" = "n" ] || [ "$response" = "N" ]
124
		if [ "$response" = "n" ] || [ "$response" = "N" ]
120
		then
125
		then
-
 
126
			[ -e /etc/urpmi/urpmi.cfg.old ] && mv /etc/urpmi/urpmi.cfg.old /etc/urpmi/urpmi.cfg # restore previous rpm conf file
121
			exit 1
127
			exit 1
122
		fi
128
		fi
123
	fi
129
	fi
124
done
130
done
125
 
131
 
Line 130... Line 136...
130
else
136
else
131
	echo "exclude=kernel*" >> /etc/dnf/dnf.conf
137
	echo "exclude=kernel*" >> /etc/dnf/dnf.conf
132
fi
138
fi
133
 
139
 
134
# Remove some RPMs in order to avoid error and automatic update
140
# Remove some RPMs in order to avoid error and automatic update
135
urpme wkhtmltopdf freeradius-ldap
141
urpme wkhtmltopdf freeradius-ldap lighttpd-mod_auth
136
 
142
 
137
# download the kernel used by ALCASAR
143
# download the kernel used by ALCASAR
138
if [ $Lang == "fr" ]
144
if [ $Lang == "fr" ]
139
then
145
then
140
	echo "Récupération du noyau Linux exploité par ALCASAR. Veuillez patienter ..."
146
	echo "Récupération du noyau Linux exploité par ALCASAR. Veuillez patienter ..."