Project

General

Profile

Download (958 Bytes) Statistics
| Branch: | Tag: | Revision:
1 1e6fdd81 Colin Smith
#!/bin/sh
2
#
3
# rc.cdrom - livedisc specific routines
4
# For pfSense
5
6 b69df786 Scott Ullrich
# Size of memory file system /conf partition
7 ab1a08b2 Scott Ullrich
partsize="6m"
8 1e6fdd81 Colin Smith
9 b69df786 Scott Ullrich
# Run some initialization routines
10
/etc/rc.d/uzip start
11
12 819ccd08 Scott Ullrich
export VARMFS_COPYDBPKG=yes
13
14 ab1a08b2 Scott Ullrich
echo -n "Starting memory file systems:"
15 75cf30df Scott Ullrich
for i in tmp varmfs etcmfs; do
16 b69df786 Scott Ullrich
       if [ -f /etc/rc.d/$i ]; then
17 ab1a08b2 Scott Ullrich
			echo -n " $i"
18
			sh /etc/rc.d/$i start
19 b69df786 Scott Ullrich
       fi
20
done
21 ab1a08b2 Scott Ullrich
echo "... done."
22 b69df786 Scott Ullrich
23
# Start PFI
24
/bin/sh /scripts/pfi start
25
26
# If PFI did not find a config, we should create
27
# a tiny mfs under /conf and populate with stock
28
# configuration.
29
if [ ! -f /conf/config.xml ]; then
30 819ccd08 Scott Ullrich
       echo -n "Generating a MFS /conf partition... "
31 b69df786 Scott Ullrich
       device=$(mdconfig -a -t malloc -s ${partsize})
32
       newfs /dev/${device} > /dev/null 2>&1
33
       mount /dev/${device} /conf
34 44a41e14 Scott Ullrich
       cp /conf.default/* /conf
35 b69df786 Scott Ullrich
       mount_nullfs /conf /cf/conf
36 6c80fac7 Scott Ullrich
       echo "done."
37 5aa8f8c7 Scott Ullrich
fi
38 1e6fdd81 Colin Smith
39
# Create some needed directories
40 23a115c5 Scott Ullrich
/bin/mkdir -p /var/db/pkg/
41
/bin/mkdir -p /var/tmp/vi.recover/