pf-tools commit: r675 [ccaillet-guest] - /trunk/sbin/mk_grubopt
parmelan-guest at users.alioth.debian.org
parmelan-guest at users.alioth.debian.org
Tue Nov 18 09:05:35 UTC 2008
Author: ccaillet-guest
Date: Tue Nov 18 09:05:35 2008
New Revision: 675
URL: http://svn.debian.org/wsvn/pf-tools/?sc=1&rev=675
Log:
Adding alternate path for private-network file in mk_grubopt
Modified:
trunk/sbin/mk_grubopt
Modified: trunk/sbin/mk_grubopt
URL: http://svn.debian.org/wsvn/pf-tools/trunk/sbin/mk_grubopt?rev=675&op=diff
==============================================================================
--- trunk/sbin/mk_grubopt (original)
+++ trunk/sbin/mk_grubopt Tue Nov 18 09:05:35 2008
@@ -40,6 +40,7 @@
my $MENU_GRUB = "/boot/grub/menu.lst" ;
my $HOSTNAME = hostname ;
my $DEST = "-" ;
+my $NET = "GLOBAL:private-network" ;
my $HELP = 0 ;
my $DEBUG = 0 ;
my $VERBOSE = 0 ;
@@ -54,6 +55,7 @@
-s --src source for GRUB configuration (default: /boot/grub/menu.lst)
-d --dst destination for modified GRUB configuration (default: /boot/grub/menu.lst)
--host hostname on which GRUB configuration applied
+ -n --net Possiblitiy for defining an alternate PATH for private-network file (default GLOBAL:private-network)
# ENDHELP
}
@@ -107,6 +109,7 @@
'src|s=s' => \$MENU_GRUB,
'dst|d=s' => \$DEST,
'host=s' => \$HOSTNAME,
+ 'net|n=s' => \$NET,
'debug' => \$DEBUG,
'help|h' => \$HELP,
'verbose|v' => \$VERBOSE
@@ -126,8 +129,8 @@
$DEST = "-" if ( $DEBUG ) ;
$VERBOSE = 1 if ( $DEBUG ) ;
-# my $NETWORK = Init_lib_net ( Get_source ( "GLOBAL:private-network" ) ) ;
-my $NETWORK = Init_lib_net ( Get_source ( "/home/totof/arch/pf-tools/test/private-network" ) ) ;
+my $NETWORK = Init_lib_net ( Get_source ( $NET ) ) ;
if ( ! Change_kopt ( Get_Cmdline ( $NETWORK, $HOSTNAME ), $MENU_GRUB, $DEST ) ) {
die "Unable to change kernel options(s) into file ".$MENU_GRUB."\n" ;
-}
+}
+
More information about the pf-tools-commits
mailing list