Changeset 691


Ignore:
Timestamp:
Nov 5, 2007 12:58:31 AM (6 years ago)
Author:
jrollins
Message:

debirf: added minimal profile, and tweaked the config file loading a
bit in make-debirf.

Location:
trunk/debirf
Files:
3 added
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/debirf/COPYING

    • Property svn:executable deleted
  • trunk/debirf/debian/changelog

    r686 r691  
    77  * mknod /dev/ttyS0 in serial-terminal plugin 
    88  * moved profiles directory to /etc/debirf/profiles 
     9  * added 'minimal' profile 
    910 
    10  -- Jameson Rollins <jrollins@fifthhorseman.net>  Sat, 03 Nov 2007 01:19:19 -0400 
     11 -- Jameson Rollins <jrollins@fifthhorseman.net>  Mon, 05 Nov 2007 00:53:26 -0500 
    1112 
    1213debirf (0.4) unstable; urgency=low 
  • trunk/debirf/debian/debirf.links

    r688 r691  
     1/usr/share/debirf/plugins/a0_store-config /etc/debirf/profiles/minimal/plugins/a0_store-config 
     2/usr/share/debirf/plugins/a0_motd /etc/debirf/profiles/minimal/plugins/a0_motd 
     3/usr/share/debirf/plugins/bootlog /etc/debirf/profiles/minimal/plugins/bootlog 
     4/usr/share/debirf/plugins/hostname /etc/debirf/profiles/minimal/plugins/hostname 
     5/usr/share/debirf/plugins/install-kernel /etc/debirf/profiles/minimal/plugins/install-kernel 
     6/usr/share/debirf/plugins/interfaces /etc/debirf/profiles/minimal/plugins/interfaces 
     7/usr/share/debirf/plugins/root-bashrc /etc/debirf/profiles/minimal/plugins/root-bashrc 
     8/usr/share/debirf/plugins/z0_remove-locales /etc/debirf/profiles/minimal/plugins/z0_remove-locales 
     9/usr/share/debirf/plugins/z1_apt-clean /etc/debirf/profiles/minimal/plugins/z1_apt-clean 
     10/usr/share/debirf/plugins/z2_motd_end /etc/debirf/profiles/minimal/plugins/z2_motd_end 
     11 
    112/usr/share/debirf/plugins/a0_store-config /etc/debirf/profiles/rescue/plugins/a0_store-config 
    213/usr/share/debirf/plugins/a0_motd /etc/debirf/profiles/rescue/plugins/a0_motd 
     
    1122/usr/share/debirf/plugins/z1_apt-clean /etc/debirf/profiles/rescue/plugins/z1_apt-clean 
    1223/usr/share/debirf/plugins/z2_motd_end /etc/debirf/profiles/rescue/plugins/z2_motd_end 
    13  
    14 /etc/debirf/profiles/rescue /etc/debirf/profiles/default 
  • trunk/debirf/fs/etc/debirf/profiles/rescue/debirf.conf

    r686 r691  
    44 
    55# label for debirf system (for hostname and initrd) 
    6 #DEBIRF_LABEL="debirf" 
     6DEBIRF_LABEL="debirf-resuce" 
    77 
    88# where to build the debirf 
  • trunk/debirf/fs/usr/sbin/make-debirf

    r676 r691  
    143143    1) 
    144144        DEBIRF_KERNEL_PACKAGE="$1" 
    145         echo "Profile not specified.  Setting profile to '$DEBIRF_PROFILE_DEFAULT'." 
     145        echo "Profile not specified.  Using default profile '$DEBIRF_PROFILE_DEFAULT'." 
    146146        DEBIRF_PROFILE="$DEBIRF_PROFILE_DEFAULT" 
    147147        ;; 
     
    162162fi 
    163163 
     164# source debirf.conf default 
     165source /usr/share/debirf/debirf.conf.defaults 
     166# source system debirf.conf 
     167if [ -f /etc/debirf/debirf.conf ] ; then 
     168    source /etc/debirf/debirf.conf 
     169fi 
     170 
    164171# check for debirf profile 
    165172if [ ! -d "$DEBIRF_PROFILE" ] ; then 
     
    168175    else 
    169176        echo "Profile '$DEBIRF_PROFILE' not found." 
    170         read -p "Continue? [y|N]: " OK 
    171         if [ -z "$OK" -o "${OK/y/Y}" != 'Y' ] ; then 
     177        read -p "Continue with defaults? [y|N]: " OK; OK=${OK:-N} 
     178        if [ "${OK/y/Y}" != 'Y' ] ; then 
    172179            failure "Aborting." 
    173180        fi 
     
    175182fi 
    176183 
    177 DEBIRF_CONF=${DEBIRF_CONF:-"$DEBIRF_PROFILE/debirf.conf"} 
    178 DEBIRF_PLUGINS=${DEBIRF_PLUGINS:-"$DEBIRF_PROFILE/plugins"} 
    179  
    180 # find debirf.conf and set unset variables with defaults. 
     184DEBIRF_CONF="$DEBIRF_PROFILE/debirf.conf" 
     185DEBIRF_PLUGINS="$DEBIRF_PROFILE/plugins" 
     186 
     187# source profile debirf.conf 
    181188if [ -f "$DEBIRF_CONF" ] ; then 
    182189    source "$DEBIRF_CONF" 
    183 else 
    184     echo "debirf.conf not found.  Using defaults." 
    185     if [ /etc/debirf/debirf.conf ] ; then 
    186         source /etc/debirf/debirf.conf 
    187     fi 
    188 fi 
    189 source /usr/share/debirf/debirf.conf.defaults || failure "Could not source config defaults." 
    190  
     190fi 
     191   
    191192# check plugins 
    192193if [ ! -d "$DEBIRF_PLUGINS" -o $(ls "$DEBIRF_PLUGINS" -1 | wc -l) = 0 ] ; then 
    193194    echo "Plugin directory '$DEBIRF_PLUGINS' is empty or does not exist." 
    194     read -p "Continue without plugins? [Y|n]: " OK 
    195     if [ "$OK" -a "${OK/y/Y}" != 'Y' ] ; then 
     195    read -p "Continue without plugins? [Y|n]: " OK; OK=${OK:-Y} 
     196    if [ "${OK/y/Y}" != 'Y' ] ; then 
    196197        failure "Aborting." 
    197198    fi 
  • trunk/debirf/fs/usr/share/debirf/common

    r686 r691  
    1717 
    1818DEBIRF_PROFILED=${DEBIRF_PROFILED:-"/etc/debirf/profiles"} 
    19 DEBIRF_PROFILE_DEFAULT=${DEBIRF_PROFILE_DEFAULT:-"$DEBIRF_PROFILED/default"} 
     19DEBIRF_PROFILE_DEFAULT=${DEBIRF_PROFILE_DEFAULT:-"$DEBIRF_PROFILED/rescue"} 
    2020 
    2121# set locale default 
  • trunk/debirf/fs/usr/share/man/man8/make-debirf.8

    r686 r691  
    3434A debirf profile is a directory in /etc/debirf/profiles or a full path 
    3535to a directory that possibly contains a debirf.conf and/or 'plugins' 
    36 sub-directory.  If a profile is not specified, the profile 'default' 
     36sub-directory.  If a profile is not specified, the profile 'rescue' 
    3737is assumed.  If that profile is not found, the default variables will 
    3838be used (see \fBENVIRONMENT\fP below). 
     
    107107.TP 
    108108/etc/debirf/debirf.conf 
     109System-wide configuration file. 
     110.TP 
    109111/etc/debirf/profiles/<profile>/debirf.conf 
    110 Default configuration file. 
     112Profile-specific configuration file. 
    111113.TP 
    112114$DEBIRF_ROOT/etc/debirf/debirf.info 
Note: See TracChangeset for help on using the changeset viewer.