]> git.ipfire.org Git - people/amarx/ipfire-3.x.git/blob - initscripts/sysconfig/rc.site
Move all packages to root.
[people/amarx/ipfire-3.x.git] / initscripts / sysconfig / rc.site
1 # Set base directory information
2 RC_BASE="/etc"
3 RC_FUNCTIONS="${RC_BASE}/init.d/ipfire-functions"
4
5 # Location of network device scripts and config files
6 NETWORK_SCRIPTS="/etc/init.d/networking"
7 NETWORK_DEVICES="/etc/sysconfig/network-devices"
8
9 # Directory to store boot process accounting information
10 # Used for boot logging and interactive flag when rootfs
11 # is not writable
12 TEMPFS_MOUNT="${RC_BASE}/init.d/boottemp"
13
14 # Bootlogging (requires a tempfs mount)
15 BOOTLOG_ENAB="yes"
16
17 # Distro Information
18 DISTRO="$(cat /etc/system-release)" # The distro name
19 DISTRO_CONTACT="http://bugtracker.ipfire.org" # Bug report address
20 DISTRO_MINI="ipfire" # Short name used in filenames for distro config
21
22 # Define custom colors used in messages printed to the screen
23 BRACKET="\\033[1;34m" # Blue
24 FAILURE="\\033[1;31m" # Red
25 INFO="\\033[1;36m" # Cyan
26 NORMAL="\\033[0;39m" # Grey
27 SUCCESS="\\033[1;32m" # Green
28 WARNING="\\033[1;33m" # Yellow
29
30 # Prefix boot messages for easier reading on framebuffer consoles
31 PREFIX_SUCCESS=" ${SUCCESS}*${NORMAL} "
32 PREFIX_WARNING="${WARNING}**${NORMAL} "
33 PREFIX_FAILURE="${FAILURE}***${NORMAL}"
34
35 # Export varialbles so that they are inherited by the initscripts
36 export RC_BASE RC_FUNCTIONS TEMPFS_MOUNT BOOTLOG_ENAB
37 export NETWORK_DEVICES NETWORK_SCRIPTS
38 export DISTRO DISTRO_CONTACT DISTRO_MINI
39 export BRACKET FAILURE INFO NORMAL SUCCESS WARNING
40 export PREFIX_SUCCESS PREFIX_WARNING PREFIX_FAILURE
41
42 # Interactive startup
43 iprompt="yes" # Wether to display the interactive boot promp
44 itime="2" # The ammount of time (in seconds) to display the prompt
45 dlen="$(( 11 + ${#DISTRO} ))" # The total length of the distro welcome string
46 ilen="38" # The total length of the interactive message
47 welcome_message="Welcome to ${INFO}${DISTRO}${NORMAL}"
48 i_message="Press '${FAILURE}I${NORMAL}' to enter interactive startup"
49
50 # Error message displayed when a script's exit value is not zero
51 print_error_msg()
52 {
53 # ${link} and ${error_value} are defined by the rc script
54 echo -e "${FAILURE}FAILURE: You should not be reading this error message."
55 echo -e ""
56 echo -e -n "${FAILURE}It means that an unforseen error took place in"
57 echo -e -n "${INFO} ${link}"
58 echo -e "${FAILURE},"
59 echo -e "${FAILURE}which exited with a return value of ${error_value}."
60 echo -e ""
61 echo -e -n "${FAILURE}If you are able to track this error down to a bug"
62 echo -e "${FAILURE}in one of the files"
63 echo -e -n "provided by ${INFO}${DISTRO}${FAILURE}, "
64 echo -e -n "${FAILURE}please be so kind to inform us at "
65 echo -e "${INFO}${DISTRO_CONTACT}${FAILURE}.${NORMAL}"
66 echo -e ""
67 echo -e "${INFO}Press Enter to continue..."
68 echo -e "${NORMAL}"
69 read ENTER
70 }
71