Subversion Repositories ALCASAR

Rev

Go to most recent revision | Details | Last modification | View Log

Rev Author Line No. Line
2682 rexy 1
#!/usr/bin/perl -cw
2
# 
3
# Configuration file written by :
4
# 	* Hamza ESSAYEGH (Querdos)
5
#
6
# /!\ Before putting this file in the iso, check the syntax with
7
# 	  `perl -cw auto_inst.cfg.pl`
8
#
9
# For more information about all options here, refer to the wiki:
10
# 	https://wiki.mageia.org/en/Auto_inst
11
#
12
$o = {
13
    # Keyboard settings
14
    'keyboard' => {
15
        'GRP_TOGGLE' => '',
16
        'KEYBOARD' => 'us'
17
    },
18
 
19
    # Locale setting
20
    # TODO: Check 
21
    'locale' => {
22
        'lang' => 'en_US',
23
        'IM' => undef,
24
        'langs' => {
25
            'fr' => 1
26
        },
27
        'country' => 'US'
28
    },
29
 
30
	# Security level: 
31
	# 	* 2 is for standard
32
	#	* 3 for High
33
	#	* 4 for Higher
34
	#	* 5 for Paranoïd
35
	'security' => 2,
36
 
37
	# Non admin user sysadmin
38
	'users' => [
39
		{
40
		'shell' 	=> '/bin/bash',
41
		'realname' 	=> 'sysadmin',
42
		'name' 		=> 'sysadmin',
43
        'pw'        => '$2a$08$0Y9PuTN.3A3T57duRBZ3YOd6LALzsRx/jEDCBiaVNBg/tA1YJvZIC',
44
		'groups' 	=> [],
45
		}
46
	],
47
 
48
	# Authentication method
49
	'authentication' => {
50
		'shadow' 	=> 1,
51
		'blowfish' 	=> 1
52
	},
53
 
54
	# Superuser (root) definition
55
	'superuser' => {
56
		'shell' 	=> '/bin/bash',
57
		'realname' 	=> 'root',
58
		'pw' 		=> '$2a$08$FJ4lI4royRd2crXB1yWvJO9BMMoBbbUw/YRX8kaQ/6zb/poOjTFM2',
59
		'home' 		=> '/root',
60
		'uid' 		=> '0',
61
		'gid' 		=> '0'
62
	},
63
 
64
	# Default packages for the new distribution
65
	# Basic package for a minimalist system, ALCASAR will handle 
66
	# the rest
67
	# TODO: Default packages for x86_64
68
	'default_packages' => [
69
		'plymouth',
70
		'aria2',
71
		'netprofile',
72
		'sudo',
73
		'cdrkit',
74
		'sharutils',
75
		'ldetect',
76
		'alsa-utils',
77
		'pm-utils',
78
		'lsof',
79
		'ntfs-3g',
80
		'nscd',
81
		'bash-completion',
82
		'mageia-gfxboot-theme',
83
		'basesystem',
84
		'dhcp-client',
85
		'aoss',
86
		'kernel-desktop-latest',
87
		'dvd+rw-tools',
88
		'vim-minimal',
89
		'acpi',
90
		'locales-fr',
91
		'mandi-ifw',
92
		'grub',
93
		'lftp',
94
		'shorewall-ipv6',
95
		'usbutils',
96
		'rtlwifi-firmware',
97
		'kernel-firmware-nonfree',
98
		'iwlwifi-agn-ucode',
99
		'radeon-firmware',
100
		'ralink-firmware',
101
		'autologin',
102
		'wget',
103
 
104
		# Packages needed by alcasar
105
        'freeradius',	
106
        'freeradius-mysql',
107
        'freeradius-ldap',
108
        'apache',		
109
        'apache-mod_ssl',
110
        'apache-mod_php',
111
        'dansguardian',
112
        'postfix',
113
        'mariadb',
114
        'ntp',
115
        'bind-utils',
116
        'openssh-server', 
117
        'php-xml',
118
        'php-ldap',
119
        'php-mysql',
120
        'php-mysqli',
121
        'php-mbstring',
122
        'php-sockets',
123
        'php-cli',
124
        'php-curl',
125
        'php-pdo_sqlite',
126
        'php-json',
127
        'rng-utils',
128
        'rsync',
129
        'clamav',
130
        'perl-rrdtool',
131
        'perl-MailTools',
132
        'perl-Socket6',
133
        'fail2ban',
134
        'gnupg',
135
        'ulogd',
136
        'pm-fallback-policy',
137
        'ipset',
138
        'cronie-anacron',
139
        'gammu',
140
        'usbutils',
141
        'locales-en',
142
        'usb_modeswitch',
143
        'tinyproxy',
144
        'vnstat',
145
        'php-gd',
146
        'sudo',
147
        'iftop',
148
        'man',
149
        'kernel-firmware-nonfree',
150
        'dos2unix'
151
	],
152
 
153
	# Partitionning : control the partitioning of the target system's 
154
	# hard disk drives
155
	'partitioning' => {
156
		# Set to 1 if disk partitions are to be defined by the 
157
		# option partitions
158
		'auto_allocate' => 1,
159
 
160
		# 1: all the existing partitions on ALL disks are to be cleared
161
		# 	 and replaced
162
		# 0: the disks are to be left untouched or, you are goeing to 
163
		#	 use "clear" instead
164
		'clearall' 		=> 1
165
	},
166
 
167
	# Partitions option is used to define the partitions that are to be 
168
	# created on the hard disk
169
	# TODO: SWAP for 64-bits
170
	'partitions' => [
171
		# First partition, 5Go -> '/' -> ext4
172
		{
173
			'mntpoint' 		=> '/',
174
			'size' 			=> 5000 << 11,
175
			'fs_type' 		=> 'ext4'
176
		},
177
 
178
		# Second partition, swap
179
		{
180
			'mntpoint' 		=> 'swap',
181
			'size' 			=> 4000 << 11,
182
			'fs_type' 		=> 'swap'
183
		},
184
 
185
		# Third partition, 5Go -> '/tmp'
186
		{
187
			'mntpoint' 		=> '/tmp',
188
			'size' 			=> 5000 << 11,
189
			'fs_type' 		=> 'ext4'
190
		},
191
 
192
		# Fourth partition, 5Go -> '/home' -> ext4
193
		{
194
			'mntpoint' 		=> '/home',
195
			'size' 			=> 5000 << 11,
196
			'fs_type' 		=> 'ext4'
197
		},
198
 
199
		# Fifth partition, /var with rest of the disk
200
		{
201
			'mntpoint' 		=> '/var',
202
			'size' 			=> 10 << 11,
203
			'ratio'			=> 100,
204
			'fs_type' 		=> 'ext4',
205
		}
206
	],
207
 
208
	# Interactive steps option
209
	# http://members.shaw.ca/mandrake/ -> section Replay Steps for 
210
	# more informations
211
	'interactiveSteps' => [
212
		# Select language(s) support to be installed.
213
		'selectLanguage',
214
 
215
		# Allows you to Accept or Refuse the License Agreement.
216
		'acceptLicense',
217
 
218
		# Select the time zone, GMT/Local hardware clock and if you 
219
		# want NTP installed.
220
		'summary'
221
	],
222
 
223
	# Post installation script, executed as root in the installed 
224
	# environments and not inside the DrakX installation program
225
	'postInstallNonRooted' => "
226
		# Copying Alcasar needed rpms
227
		tar -xf /tmp/image/install/alcasar/rpms-*.tar.gz -C /mnt/var/cache/urpmi/rpms
228
 
229
		# Copying Alcasar archive to the root directory
230
		tar -xf /tmp/image/install/alcasar/alcasar.tar.gz -C /mnt/root/
231
 
232
		# Copying the first login script to the root directory
233
		cp /tmp/image/install/alcasar/first_login /mnt/root/
234
 
235
		# Editing bashrc
236
		echo '[[ -f first_login ]] && bash first_login;' >> /mnt/root/.bashrc
237
	",
238
 
239
	# Exit without prompt after installation is finished
240
	# 0 - prompt the installer to re-boot and wait
241
	# 1 - reboot the computer automatically
242
	'autoExitInstall' => 1
243
};