diff options
Diffstat (limited to 'etc')
| -rw-r--r-- | etc/.gitignore | 3 | ||||
| -rw-r--r-- | etc/Makefile | 28 | ||||
| -rw-r--r-- | etc/devd.conf | 315 | ||||
| -rw-r--r-- | etc/rc.conf.DragonFly | 13 | ||||
| -rw-r--r-- | etc/rc.conf.FreeBSD | 13 | ||||
| -rw-r--r-- | etc/rc.conf.GNU | 14 | ||||
| -rw-r--r-- | etc/rc.conf.GNU-kFreeBSD | 11 | ||||
| -rw-r--r-- | etc/rc.conf.Linux | 78 | ||||
| -rw-r--r-- | etc/rc.conf.NetBSD | 14 | ||||
| -rw-r--r-- | etc/rc.conf.in | 145 | ||||
| -rw-r--r-- | etc/rc.devd | 32 | ||||
| -rw-r--r-- | etc/rc.in | 19 | ||||
| -rw-r--r-- | etc/rc.shutdown.in | 17 |
13 files changed, 0 insertions, 702 deletions
diff --git a/etc/.gitignore b/etc/.gitignore deleted file mode 100644 index 6d86e6da..00000000 --- a/etc/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -rc.conf -rc -rc.shutdown diff --git a/etc/Makefile b/etc/Makefile deleted file mode 100644 index 53bf47cc..00000000 --- a/etc/Makefile +++ /dev/null @@ -1,28 +0,0 @@ -DIR= ${SYSCONFDIR} -SRCS= rc.conf.in rc.in rc.shutdown.in -BIN= ${BIN-${OS}} -CONF= rc.conf ${BIN-${OS}} - -CLEANFILES+= rc.conf - -MK= ../mk -include ${MK}/os.mk - -SED_EXTRA-FreeBSD= -e 's:@TERM@:cons25:g' -BIN-FreeBSD= rc rc.shutdown rc.devd -CONF-FreeBSD= devd.conf - -SED_EXTRA-Linux= -e 's:@TERM@:wsvt25:g' -BIN-Linux= -CONF-Linux= - -SED_EXTRA-NetBSD= -e 's:@TERM@:wsvt25:g' -BIN-NetBSD= rc rc.shutdown -CONF-NetBSD= - -SED_EXTRA= ${SED_EXTRA-${OS}} - -include ${MK}/scripts.mk - -rc.conf: rc.conf.in rc.conf.${OS} - ${SED} ${SED_REPLACE} ${SED_EXTRA} $^ > $@ diff --git a/etc/devd.conf b/etc/devd.conf deleted file mode 100644 index 3cd262cf..00000000 --- a/etc/devd.conf +++ /dev/null @@ -1,315 +0,0 @@ -# $FreeBSD: src/etc/devd.conf,v 1.38 2007/06/21 22:50:36 njl Exp $ -# -# Refer to devd.conf(5) and devd(8) man pages for the details on how to -# run and configure devd. -# - -# NB: All regular expressions have an implicit ^$ around them. -# NB: device-name is shorthand for 'match device-name' - -options { - # Each directory directive adds a directory the list of directories - # that we scan for files. Files are read-in in the order that they - # are returned from readdir(3). The rule-sets are combined to - # create a DFA that's used to match events to actions. - directory "/etc/devd"; - directory "/usr/local/etc/devd"; - pid-file "/var/run/devd.pid"; - - # Setup some shorthand for regex that we use later in the file. - #XXX Yes, these are gross -- imp - set scsi-controller-regex - "(aac|adv|adw|aha|ahb|ahc|ahd|aic|amd|amr|asr|bt|ciss|ct|dpt|\ - esp|ida|iir|ips|isp|mlx|mly|mpt|ncr|ncv|nsp|stg|sym|trm|wds)\ - [0-9]+"; -}; - -# Note that the attach/detach with the highest value wins, so that one can -# override these general rules. - -# -# Configure the interface on attach. Due to a historical accident, this -# script is called pccard_ether. -# -notify 0 { - match "system" "IFNET"; - match "type" "ATTACH"; - action "/etc/rc.devd net.$subsystem start"; -}; - -notify 0 { - match "system" "IFNET"; - match "type" "DETACH"; - action "/etc/rc.devd net.$subsystem stop"; -}; - -# -# Try to configure the interface when the network comes up and deconfigure -# when it goes down -# -notify 0 { - match "system" "IFNET"; - match "type" "LINK_UP"; - media-type "ethernet"; - action "/etc/rc.devd net.$subsystem start"; -}; - -notify 0 { - match "system" "IFNET"; - match "type" "LINK_DOWN"; - media-type "ethernet"; - action "/etc/rc.devd net.$subsystem stop"; -}; -# -# Like Ethernet devices, but separate because -# they have a different media type. We may want -# to exploit this later. -# -detach 0 { - media-type "802.11"; - action "/etc/rc.devd net.$device-name stop"; -}; -attach 0 { - media-type "802.11"; - action "/etc/rc.devd net.$device-name start"; -}; -notify 0 { - match "system" "IFNET"; - match "type" "LINK_UP"; - media-type "802.11"; - action "/etc/rc.devd net.$subsystem start"; -}; -notify 0 { - match "system" "IFNET"; - match "type" "LINK_DOWN"; - media-type "802.11"; - action "/etc/rc.devd net.$subsystem stop"; -}; - -# An entry like this might be in a different file, but is included here -# as an example of how to override things. Normally 'ed50' would match -# the above attach/detach stuff, but the value of 100 makes it -# hard wired to 1.2.3.4. -attach 100 { - device-name "ed50"; - action "ifconfig $device-name inet 1.2.3.4 netmask 0xffff0000"; -}; -detach 100 { - device-name "ed50"; -}; - -# When a USB Bluetooth dongle appears activate it -attach 100 { - device-name "ubt[0-9]+"; - action "/etc/rc.d/bluetooth start $device-name"; -}; -detach 100 { - device-name "ubt[0-9]+"; - action "/etc/rc.d/bluetooth stop $device-name"; -}; - -# When a USB keyboard arrives, attach it as the console keyboard. -attach 100 { - device-name "ukbd0"; - action "/etc/rc.d/syscons setkeyboard /dev/ukbd0"; -}; -detach 100 { - device-name "ukbd0"; - action "/etc/rc.d/syscons setkeyboard /dev/kbd0"; -}; - -# The entry below starts moused when a mouse is plugged in. Moused -# stops automatically (actually it bombs :) when the device disappears. -attach 100 { - device-name "ums[0-9]+"; - action "/etc/rc.devd moused.$device-name start"; -}; - -# Firmware download into the ActiveWire board. After the firmware download is -# done the device detaches and reappears as something new and shiny -# automatically. -attach 100 { - match "vendor" "0x0854"; - match "product" "0x0100"; - match "release" "0x0000"; - action "/usr/local/bin/ezdownload -f /usr/local/share/usb/firmware/0854.0100.0_01.hex $device-name"; -}; - -# Firmware download for Entrega Serial DB25 adapter. -attach 100 { - match "vendor" "0x1645"; - match "product" "0x8001"; - match "release" "0x0101"; - action "if ! kldstat -n usio > /dev/null 2>&1 ; then kldload usio; fi /usr/sbin/ezdownload -v -f /usr/share/usb/firmware/1645.8001.0101 /dev/$device-name"; -}; - -# This entry starts the ColdSync tool in daemon mode. Make sure you have an up -# to date /usr/local/etc/palms. We override the 'listen' settings for port and -# type in /usr/local/etc/coldsync.conf. -attach 100 { - device-name "ugen[0-9]+"; - match "vendor" "0x082d"; - match "product" "0x0100"; - match "release" "0x0100"; - action "/usr/local/bin/coldsync -md -p /dev/$device-name -t usb"; -}; - -# -# Rescan scsi device-names on attach, but not detach. However, it is -# disabled by default due to reports of problems. -# -attach 0 { - device-name "$scsi-controller-regex"; -// action "camcontrol rescan all"; -}; - -# Don't even try to second guess what to do about drivers that don't -# match here. Instead, pass it off to syslog. Commented out for the -# moment, as the pnpinfo variable isn't set in devd yet. Individual -# variables within the bus supplied pnpinfo are set. -nomatch 0 { -# action "logger Unknown device: $pnpinfo $location $bus"; -}; - -# Various logging of unknown devices. -nomatch 10 { - match "bus" "uhub[0-9]+"; - action "logger Unknown USB device: vendor $vendor product $product \ - bus $bus"; -}; - -# Some PC-CARDs don't offer numerical manufacturer/product IDs, just -# show the CIS info there. -nomatch 20 { - match "bus" "pccard[0-9]+"; - match "manufacturer" "0xffffffff"; - match "product" "0xffffffff"; - action "logger Unknown PCCARD device: CISproduct $cisproduct \ - CIS-vendor $cisvendor bus $bus"; -}; - -nomatch 10 { - match "bus" "pccard[0-9]+"; - action "logger Unknown PCCARD device: manufacturer $manufacturer \ - product $product CISproduct $cisproduct CIS-vendor \ - $cisvendor bus $bus"; -}; - -nomatch 10 { - match "bus" "cardbus[0-9]+"; - action "logger Unknown Cardbus device: device $device class $class \ - vendor $vendor bus $bus"; -}; - -# Switch power profiles when the AC line state changes. -notify 10 { - match "system" "ACPI"; - match "subsystem" "ACAD"; - action "/etc/rc.d/power_profile $notify"; -}; - -# Notify all users before beginning emergency shutdown when we get -# a _CRT or _HOT thermal event and we're going to power down the system -# very soon. -notify 10 { - match "system" "ACPI"; - match "subsystem" "Thermal"; - match "notify" "0xcc"; - action "logger -p kern.emerg 'WARNING: system temperature too high, shutting down soon!'"; -}; - -# Sample ZFS problem reports handling. -notify 10 { - match "system" "ZFS"; - match "type" "zpool"; - action "logger -p kern.err 'ZFS: failed to load zpool $pool'"; -}; - -notify 10 { - match "system" "ZFS"; - match "type" "vdev"; - action "logger -p kern.err 'ZFS: vdev failure, zpool=$pool type=$type'"; -}; - -notify 10 { - match "system" "ZFS"; - match "type" "data"; - action "logger -p kern.warn 'ZFS: zpool I/O failure, zpool=$pool error=$zio_err'"; -}; - -notify 10 { - match "system" "ZFS"; - match "type" "io"; - action "logger -p kern.warn 'ZFS: vdev I/O failure, zpool=$pool path=$vdev_path offset=$zio_offset size=$zio_size error=$zio_err'"; -}; - -notify 10 { - match "system" "ZFS"; - match "type" "checksum"; - action "logger -p kern.warn 'ZFS: checksum mismatch, zpool=$pool path=$vdev_path offset=$zio_offset size=$zio_size'"; -}; - -# User requested suspend, so perform preparation steps and then execute -# the actual suspend process. -notify 10 { - match "system" "ACPI"; - match "subsystem" "Suspend"; - action "/etc/rc.suspend acpi $notify"; -}; -notify 10 { - match "system" "ACPI"; - match "subsystem" "Resume"; - action "/etc/rc.resume acpi $notify"; -}; - -/* EXAMPLES TO END OF FILE - -# The following might be an example of something that a vendor might -# install if you were to add their device. This might reside in -# /usr/local/etc/devd/deqna.conf. A deqna is, in this hypothetical -# example, a pccard ethernet-like device. Students of history may -# know other devices by this name, and will get the in-jokes in this -# entry. -nomatch 10 { - match "bus" "pccard[0-9]+"; - match "manufacturer" "0x1234"; - match "product" "0x2323"; - action "kldload if_deqna"; -}; -attach 10 { - device-name "deqna[0-9]+"; - action "/etc/pccard_ether $device-name start"; -}; -detach 10 { - device-name "deqna[0-9]+"; - action "/etc/pccard_ether $device-name stop"; -}; - -# Examples of notify hooks. A notify is a generic way for a kernel -# subsystem to send event notification to userland. -# -# Here are some examples of ACPI notify handlers. ACPI subsystems that -# generate notifies include the AC adapter, power/sleep buttons, -# control method batteries, lid switch, and thermal zones. -# -# Information returned is not always the same as the ACPI notify -# events. See the ACPI specification for more information about -# notifies. Here is the information returned for each subsystem: -# -# ACAD: AC line state (0 is offline, 1 is online) -# Button: Button pressed (0 for power, 1 for sleep) -# CMBAT: ACPI battery events -# Lid: Lid state (0 is closed, 1 is open) -# Suspend, Resume: Suspend and resume notification -# Thermal: ACPI thermal zone events -# -# This example calls a script when the AC state changes, passing the -# notify value as the first argument. If the state is 0x00, it might -# call some sysctls to implement economy mode. If 0x01, it might set -# the mode to performance. -notify 10 { - match "system" "ACPI"; - match "subsystem" "ACAD"; - action "/etc/acpi_ac $notify"; -}; -*/ diff --git a/etc/rc.conf.DragonFly b/etc/rc.conf.DragonFly deleted file mode 100644 index 208bcc16..00000000 --- a/etc/rc.conf.DragonFly +++ /dev/null @@ -1,13 +0,0 @@ -############################################################################## -# DragonFly BSD SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on DragonFly BSD: -# "" - nothing special -# "jail" - DragonFly BSD jails -# "prefix" - Prefix -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" - diff --git a/etc/rc.conf.FreeBSD b/etc/rc.conf.FreeBSD deleted file mode 100644 index cb16b83a..00000000 --- a/etc/rc.conf.FreeBSD +++ /dev/null @@ -1,13 +0,0 @@ -############################################################################## -# FreeBSD SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on FreeBSD: -# "" - nothing special -# "jail" - FreeBSD jails -# "prefix" - Prefix -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" - diff --git a/etc/rc.conf.GNU b/etc/rc.conf.GNU deleted file mode 100644 index a9f054ae..00000000 --- a/etc/rc.conf.GNU +++ /dev/null @@ -1,14 +0,0 @@ -############################################################################## -# GNU/Hurd SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on GNU/Hurd: -# "" - nothing special -# "subhurd" - Hurd subhurds (to be checked) -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" -# This is the number of tty's used in most of the rc-scripts (like -# consolefont, numlock, etc ...) -#rc_tty_number=6? diff --git a/etc/rc.conf.GNU-kFreeBSD b/etc/rc.conf.GNU-kFreeBSD deleted file mode 100644 index 67fe2ae4..00000000 --- a/etc/rc.conf.GNU-kFreeBSD +++ /dev/null @@ -1,11 +0,0 @@ -############################################################################## -# GNU/kFreeBSD SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on GNU/kFreeBSD: -# "" - nothing special -# "jail" - FreeBSD jails (not yet implemented) -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" diff --git a/etc/rc.conf.Linux b/etc/rc.conf.Linux deleted file mode 100644 index 79bd9713..00000000 --- a/etc/rc.conf.Linux +++ /dev/null @@ -1,78 +0,0 @@ -############################################################################## -# LINUX SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on Linux: -# "" - nothing special -# "lxc" - Linux Containers -# "openvz" - Linux OpenVZ -# "prefix" - Prefix -# "uml" - Usermode Linux -# "vserver" - Linux vserver -# "xen0" - Xen0 Domain -# "xenU" - XenU Domain -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" - -# This is the number of tty's used in most of the rc-scripts (like -# consolefont, numlock, etc ...) -rc_tty_number=12 - -############################################################################## -# CGROUPS RESOURCE MANAGEMENT - -# If you have cgroups turned on in your kernel, this switch controls -# whether or not a group for each controller is mounted under -# /sys/fs/cgroup. -# None of the other options in this section work if this is set to "NO". -#rc_controller_cgroups="YES" - -# The following settings allow you to set up values for the cgroup -# controllers for your services. -# They can be set in this file;, however, if you do this, the settings -# will apply to all of your services. -# If you want different settings for each service, place the settings in -# /etc/conf.d/foo for service foo. -# The format is to specify the names of the settings followed by their -# values. Each variable can hold multiple settings. -# For example, you would use this to set the cpu.shares setting in the -# cpu controller to 512 for your service. -# rc_cgroup_cpu=" -# cpu.shares 512 -# " -# -#For more information about the adjustments that can be made with -#cgroups, see Documentation/cgroups/* in the linux kernel source tree. - -# Set the blkio controller settings for this service. -#rc_cgroup_blkio="" - -# Set the cpu controller settings for this service. -#rc_cgroup_cpu="" - -# Add this service to the cpuacct controller (any value means yes). -#rc_cgroup_cpuacct="" - -# Set the cpuset controller settings for this service. -#rc_cgroup_cpuset="" - -# Set the devices controller settings for this service. -#rc_cgroup_devices="" - -# Set the memory controller settings for this service. -#rc_cgroup_memory="" - -# Set the net_prio controller settings for this service. -#rc_cgroup_net_prio="" - -# Set this to YES if yu want all of the processes in a service's cgroup -# killed when the service is stopped or restarted. -# This should not be set globally because it kills all of the service's -# child processes, and most of the time this is undesirable. Please set -# it in /etc/conf.d/<service>. -# To perform this cleanup manually for a stopped service, you can -# execute cgroup_cleanup with /etc/init.d/<service> cgroup_cleanup or -# rc-service <service> cgroup_cleanup. -# rc_cgroup_cleanup="NO" diff --git a/etc/rc.conf.NetBSD b/etc/rc.conf.NetBSD deleted file mode 100644 index 43f8b886..00000000 --- a/etc/rc.conf.NetBSD +++ /dev/null @@ -1,14 +0,0 @@ -############################################################################## -# NetBSD SPECIFIC OPTIONS - -# This is the subsystem type. Valid options on NetBSD: -# "" - nothing special -# "prefix" - Prefix -# "xen0" - Xen0 Domain -# "xenU" - XenU Domain -# If this is commented out, automatic detection will be used. -# -# This should be set to the value representing the environment this file is -# PRESENTLY in, not the virtualization the environment is capable of. -#rc_sys="" - diff --git a/etc/rc.conf.in b/etc/rc.conf.in deleted file mode 100644 index 69a5cf24..00000000 --- a/etc/rc.conf.in +++ /dev/null @@ -1,145 +0,0 @@ -# Global OpenRC configuration settings - -# Set to "YES" if you want the rc system to try and start services -# in parallel for a slight speed improvement. When running in parallel we -# prefix the service output with its name as the output will get -# jumbled up. -# WARNING: whilst we have improved parallel, it can still potentially lock -# the boot process. Don't file bugs about this unless you can supply -# patches that fix it without breaking other things! -#rc_parallel="NO" - -# Set rc_interactive to "YES" and you'll be able to press the I key during -# boot so you can choose to start specific services. Set to "NO" to disable -# this feature. This feature is automatically disabled if rc_parallel is -# set to YES. -#rc_interactive="YES" - -# If we need to drop to a shell, you can specify it here. -# If not specified we use $SHELL, otherwise the one specified in /etc/passwd, -# otherwise /bin/sh -# Linux users could specify /sbin/sulogin -#rc_shell=/bin/sh - -# Do we allow any started service in the runlevel to satisfy the dependency -# or do we want all of them regardless of state? For example, if net.eth0 -# and net.eth1 are in the default runlevel then with rc_depend_strict="NO" -# both will be started, but services that depend on 'net' will work if either -# one comes up. With rc_depend_strict="YES" we would require them both to -# come up. -#rc_depend_strict="YES" - -# rc_hotplug is a list of services that we allow to be hotplugged. -# By default we do not allow hotplugging. -# A hotplugged service is one started by a dynamic dev manager when a matching -# hardware device is found. -# This service is intrinsically included in the boot runlevel. -# To disable services, prefix with a ! -# Example - rc_hotplug="net.wlan !net.*" -# This allows net.wlan and any service not matching net.* to be plugged. -# Example - rc_hotplug="*" -# This allows all services to be hotplugged -#rc_hotplug="*" - -# rc_logger launches a logging daemon to log the entire rc process to -# /var/log/rc.log -# NOTE: Linux systems require the devfs service to be started before -# logging can take place and as such cannot log the sysinit runlevel. -#rc_logger="YES" - -# Through rc_log_path you can specify a custom log file. -# The default value is: /var/log/rc.log -#rc_log_path="/var/log/rc.log" - -# If you want verbose output for OpenRC, set this to yes. If you want -# verbose output for service foo only, set it to yes in /etc/conf.d/foo. -#rc_verbose=no - -# By default we filter the environment for our running scripts. To allow other -# variables through, add them here. Use a * to allow all variables through. -#rc_env_allow="VAR1 VAR2" - -# By default we assume that all daemons will start correctly. -# However, some do not - a classic example is that they fork and return 0 AND -# then child barfs on a configuration error. Or the daemon has a bug and the -# child crashes. You can set the number of milliseconds start-stop-daemon -# waits to check that the daemon is still running after starting here. -# The default is 0 - no checking. -#rc_start_wait=100 - -# rc_nostop is a list of services which will not stop when changing runlevels. -# This still allows the service itself to be stopped when called directly. -#rc_nostop="" - -# rc will attempt to start crashed services by default. -# However, it will not stop them by default as that could bring down other -# critical services. -#rc_crashed_stop=NO -#rc_crashed_start=YES - -# Set rc_nocolor to yes if you do not want colors displayed in OpenRC -# output. -#rc_nocolor=NO - -############################################################################## -# MISC CONFIGURATION VARIABLES -# There variables are shared between many init scripts - -# Set unicode to YES to turn on unicode support for keyboards and screens. -#unicode="NO" - -# This is how long fuser should wait for a remote server to respond. The -# default is 60 seconds, but it can be adjusted here. -#rc_fuser_timeout=60 - -# Below is the default list of network fstypes. -# -# afs ceph cifs coda davfs fuse fuse.sshfs gfs glusterfs lustre ncpfs -# nfs nfs4 ocfs2 shfs smbfs -# -# If you would like to add to this list, you can do so by adding your -# own fstypes to the following variable. -#extra_net_fs_list="" - -############################################################################## -# SERVICE CONFIGURATION VARIABLES -# These variables are documented here, but should be configured in -# /etc/conf.d/foo for service foo and NOT enabled here unless you -# really want them to work on a global basis. -# If your service has characters in its name which are not legal in -# shell variable names and you configure the variables for it in this -# file, those characters should be replaced with underscores in the -# variable names as shown below. - -# Some daemons are started and stopped via start-stop-daemon. -# We can set some things on a per service basis, like the nicelevel. -#SSD_NICELEVEL="-19" - -# Pass ulimit parameters -#rc_ulimit="-u 30" - -# It's possible to define extra dependencies for services like so -#rc_config="/etc/foo" -#rc_need="openvpn" -#rc_use="net.eth0" -#rc_after="clock" -#rc_before="local" -#rc_provide="!net" - -# You can also enable the above commands here for each service. Below is an -# example for service foo. -#rc_foo_config="/etc/foo" -#rc_foo_need="openvpn" -#rc_foo_after="clock" - -# Below is an example for service foo-bar. Note that the '-' is illegal -# in a shell variable name, so we convert it to an underscore. -# example for service foo-bar. -#rc_foo_bar_config="/etc/foo-bar" -#rc_foo_bar_need="openvpn" -#rc_foo_bar_after="clock" - -# You can also remove dependencies. -# This is mainly used for saying which servies do NOT provide net. -#rc_net_tap0_provide="!net" - diff --git a/etc/rc.devd b/etc/rc.devd deleted file mode 100644 index 11f27ebf..00000000 --- a/etc/rc.devd +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh -# Copyright (c) 2007-2008 Roy Marples <roy@marples.name> -# Released under the 2-clause BSD license. - -# Inform RC that we are in the background and hotplugged -IN_BACKGROUND=yes -IN_HOTPLUG=yes -export IN_BACKGROUND IN_HOTPLUG - -getmedia() { - ifconfig "$1" | while read line; do - case "${line}" in - media:" "*) echo "${line}"; return;; - esac - done -} - -# Try and create an init script for network interfaces -if [ ! -e /etc/init.d/"$1" -a ! -e /usr/local/init.d/"$1" ]; then - base=${1%%.*} - if [ "${base}" = "net" ]; then - # We only create links for pyhsical interfaces - [ -n "$(getmedia ${1#*.})" ] || exit 1 - base="net.lo0" - fi - if [ -e /etc/init.d/"${base}" -a "${base}" != "$1" ]; then - ln -s "${base}" /etc/init.d/"$1" - fi -fi - -# Run the init script -exec /etc/init.d/"$1" "$2" diff --git a/etc/rc.in b/etc/rc.in deleted file mode 100644 index 864bd1ba..00000000 --- a/etc/rc.in +++ /dev/null @@ -1,19 +0,0 @@ -#!@SHELL@ -# Copyright (c) 2007-2008 Roy Marples <roy@marples.name> -# Released under the 2-clause BSD license. - -# If $TERM is not set then assume default of @TERM@ -# This gives us a nice colour boot :) -[ -z "$TERM" -o "$TERM" = "dumb" ] && TERM="@TERM@" && export TERM - -# Handle interrupts -trap : SIGINT -trap "echo 'Boot interrupted'; exit 1" SIGQUIT - -/sbin/rc sysinit || exit 1 -/sbin/rc boot || exit 1 -/sbin/rc default - -# We don't actually care if rc default worked or not, we should exit 0 -# to allow logins -exit 0 diff --git a/etc/rc.shutdown.in b/etc/rc.shutdown.in deleted file mode 100644 index 216e2f84..00000000 --- a/etc/rc.shutdown.in +++ /dev/null @@ -1,17 +0,0 @@ -#!@SHELL@ -# Copyright (c) 2007-2008 Roy Marples <roy@marples.name> -# Released under the 2-clause BSD license. - -# Handle interrupts -trap : SIGINT SIGQUIT - -# Try and use stuff in /lib over anywhere else so we can shutdown -# local mounts correctly. -LD_LIBRARY_PATH="/lib${LD_LIBRARY_PATH:+:}${LDLIBRARY_PATH}" ; export LD_LIBRARY_PATH - -# If $TERM is not set then assume default of @TERM@ -# This gives us a nice colour boot :) -[ -z "$TERM" -o "$TERM" = "dumb" ] && TERM="@TERM@" && export TERM - -action=${1:-shutdown} -exec /sbin/rc "${action}" |
