Subversion Repositories ALCASAR

Rev

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

Rev 1210 Rev 1211
Line 1... Line 1...
1
#!/bin/bash
1
#!/bin/bash
2
#  $Id: alcasar.sh 1210 2013-09-17 12:34:32Z crox53 $ 
2
#  $Id: alcasar.sh 1211 2013-09-17 15:19:57Z crox53 $ 
3
 
3
 
4
# alcasar.sh
4
# alcasar.sh
5
 
5
 
6
# ALCASAR Install script -  CopyLeft ALCASAR Team [Rexy + 3abtux + Steweb + Crox + ...] 
6
# ALCASAR Install script -  CopyLeft ALCASAR Team [Rexy + 3abtux + Steweb + Crox + ...] 
7
# Ce programme est un logiciel libre ; This software is free and open source
7
# Ce programme est un logiciel libre ; This software is free and open source
Line 65... Line 65...
65
PASSWD_FILE="/root/ALCASAR-passwords.txt"	# text file with the passwords and shared secrets
65
PASSWD_FILE="/root/ALCASAR-passwords.txt"	# text file with the passwords and shared secrets
66
# ******* DBMS parameters - paramètres SGBD ********
66
# ******* DBMS parameters - paramètres SGBD ********
67
DB_RADIUS="radius"				# nom de la base de données utilisée par le serveur FreeRadius
67
DB_RADIUS="radius"				# nom de la base de données utilisée par le serveur FreeRadius
68
DB_USER="radius"				# nom de l'utilisateur de la base de données
68
DB_USER="radius"				# nom de l'utilisateur de la base de données
69
# ******* Network parameters - paramètres réseau *******
69
# ******* Network parameters - paramètres réseau *******
70
HOSTNAME="alcasar.localdomain"				# 
70
HOSTNAME="alcasar"				# 
71
DOMAIN="localdomain"				# domaine local
71
DOMAIN="localdomain"				# domaine local
72
EXTIF="eth0"					# ETH0 est l'interface connectée à Internet (Box FAI)
72
EXTIF="eth0"					# ETH0 est l'interface connectée à Internet (Box FAI)
73
MTU="1500"
73
MTU="1500"
74
ETHTOOL_OPTS='"autoneg off speed 100 duplex full"'
74
ETHTOOL_OPTS='"autoneg off speed 100 duplex full"'
75
INTIF="eth1"					# ETH1 est l'interface connectée au réseau local de consultation
75
INTIF="eth1"					# ETH1 est l'interface connectée au réseau local de consultation
Line 1307... Line 1307...
1307
EOF
1307
EOF
1308
 
1308
 
1309
# Init file modification
1309
# Init file modification
1310
[ -e /etc/init.d/dnsmasq.default ] || cp /etc/init.d/dnsmasq /etc/init.d/dnsmasq.default
1310
[ -e /etc/init.d/dnsmasq.default ] || cp /etc/init.d/dnsmasq /etc/init.d/dnsmasq.default
1311
# Start and stop a 2nd process for the "DNS blackhole"
1311
# Start and stop a 2nd process for the "DNS blackhole"
1312
$SED "/daemon/a \$dnsmasq -C /etc/dnsmasq-blackhole.conf \$OPTIONS" /etc/init.d/dnsmasq
-
 
1313
$SED "/killproc \$DAEMON_NAME/a killproc \$DAEMON_NAME" /etc/init.d/dnsmasq
1312
cp -f $DIR_CONF/dnsmasq /etc/init.d/dnsmasq			
1314
# Start after chilli (65) which create tun0
1313
# Start after chilli (65) which create tun0
1315
$SED "s?^# chkconfig:.*?# chkconfig: 2345 99 40?g" /etc/init.d/dnsmasq
1314
$SED "s?^# chkconfig:.*?# chkconfig: 2345 99 40?g" /etc/init.d/dnsmasq
1316
# Optionnellement on pré-active les logs DNS des clients
1315
# Optionnellement on pré-active les logs DNS des clients
1317
[ -e /etc/sysconfig/dnsmasq.default ] || cp /etc/sysconfig/dnsmasq /etc/sysconfig/dnsmasq.default
1316
[ -e /etc/sysconfig/dnsmasq.default ] || cp /etc/sysconfig/dnsmasq /etc/sysconfig/dnsmasq.default
1318
$SED "s?log-facility?#OPTIONS=\"-q --log-facility=/var/log/dnsmasq/queries.log\"?g"  /etc/sysconfig/dnsmasq
1317
$SED "s?log-facility?#OPTIONS=\"-q --log-facility=/var/log/dnsmasq/queries.log\"?g"  /etc/sysconfig/dnsmasq