bootdisk: installer-validate (HEAD) installer.conf (HEAD)
malekith
malekith w pld.org.pl
Pon, 17 Lut 2003, 23:22:42 CET
Module name: bootdisk
Changes by: malekith 03/02/17 23:22:39
Modified files:
installer-validate installer.conf
Log message:
- source_additiona, #1
Index: installer-validate
===================================================================
RCS file: /cvsroot/bootdisk/batch-installer/installer-validate,v
diff -d -u -r1.78 -r1.79
--- installer-validate 23 Aug 2002 12:44:48 -0000 1.78
+++ installer-validate 17 Feb 2003 22:22:37 -0000 1.79
@@ -199,10 +199,10 @@
if test "$2"; then val=$2; else : ; eval "val=\$${1}"; fi
is_not_empty $1
is_not_list $1
- if echo "$val" | grep -q "^[a-zA-Z0-9_/\.\-]*$"; then
+ if echo "$val" | grep -q "^[a-zA-Z0-9_/\.+\-]*$"; then
: is ok
else
- error $1 "`nls "weird dirname %s. Allowed chars: letters, digits %s" "$val" ", /_-."`"
+ error $1 "`nls "weird dirname %s. Allowed chars: letters, digits %s" "$val" ", /+_-."`"
fi
}
@@ -279,7 +279,7 @@
check_url_hostname () {
local val proto rest port host
- eval "val=\$${1}"
+ val="$2"
val=`echo $val | sed -e 's|/*$||' || :`
proto=ftp # default
rest=$val
@@ -339,7 +339,7 @@
net)
is_equal source_filesystem net
is_not_auto source_device
- check_url_hostname source_device
+ check_url_hostname source_device "$source_device"
is_not_auto source_dir
need_net=yes
;;
@@ -374,6 +374,25 @@
error source "`nls "%s not supported" "$source"`"
;;
esac
+
+ for src in $source_additional ; do
+ case "$src" in
+ /* | file://* )
+ is_absolute_dirname source_additional "$(echo "$src" | sed -e 's|^file:/||')"
+ ;;
+ http://* | ftp://* )
+ case "$source" in
+ net | nfs )
+ check_url_hostname source_additional "$src"
+ ;;
+ * )
+ error source_additional "$(nls "additional source requires network")"
+ esac
+ ;;
+ *)
+ error source_additional "$(nls "invalid additional source: '%s'" "$src")"
+ esac
+ done
}
check_net () {
@@ -445,7 +464,7 @@
fi
if test "$net_proxy" -a "$net_proxy" != none ; then
- check_url_hostname net_proxy
+ check_url_hostname net_proxy "$net_proxy"
case $net_proxy in
http://* )
: ok
Index: installer.conf
===================================================================
RCS file: /cvsroot/bootdisk/batch-installer/installer.conf,v
diff -d -u -r1.16 -r1.17
--- installer.conf 29 Jul 2002 11:13:52 -0000 1.16
+++ installer.conf 17 Feb 2003 22:22:37 -0000 1.17
@@ -1,5 +1,5 @@
##
-## Generated automatically by ui at Sat Jul 27 13:20:25 CEST 2002
+## Generated automatically by ui at Mon Feb 17 23:20:34 CET 2003
##
# source is one of:
@@ -12,10 +12,13 @@
# server name with optional protocol for net, ftp:// is the default.
# source_dir: exact directory where installation files
# (RPMS and installer directory) reside
+# source_additional: space separated, additional sources for package
+# installation. You need to specify http://, ftp:// or file://.
source="cdrom"
source_device="auto"
source_filesystem="iso9660"
source_dir="/"
+source_additional=""
# net_device: example: eth0
# net_device_module: examples: ne2k-pci, auto
Więcej informacji o liście dyskusyjnej pld-installer