[dl-x86solaris-devel 120] CVS update: dlkit2/sv

Back to archive index

teelime teeli****@users*****
2006年 8月 23日 (水) 00:57:26 JST


Index: dlkit2/sv/cleaninfo-client.sub
diff -u /dev/null dlkit2/sv/cleaninfo-client.sub:1.1.2.1
--- /dev/null	Wed Aug 23 00:57:26 2006
+++ dlkit2/sv/cleaninfo-client.sub	Wed Aug 23 00:57:26 2006
@@ -0,0 +1,54 @@
+#!/bin/sh
+# -*- shell-script -*-
+# cleaninfo-client.sub - cleanup the specified client information.
+#
+# Copyright (c) 2006 SAWADA Keiji <card_capto****@users*****>
+# Copyright (c) 2005-2006 teelime <teeli****@users*****>
+#
+# This program is free software and has two license options; GNU
+# General Public License, or Common Development and Distribution
+# License.  You can and must select one when you redistribute and/or
+# modify this program.  Whatever you choose, this software comes with
+# absolutely no warranty.
+
+set -eu
+cl_pool=pool/$CL_CONFIG
+
+echon() {
+    printf "%s" "$@"
+}
+
+yesno()
+{
+	msg="$1"
+	def="$2"
+	while true ; do
+	echon "$msg"
+	read answer
+	if [ "$answer" ] ; then
+		case "$answer" in
+		y|Y|yes|YES)
+			return 0
+			;;
+		n|N|no|NO)
+			return 1
+			;;
+		*)
+			echo " "
+			echo "ERROR: Invalid response, expected \"yes\" or \"no\"."
+			continue
+			;;
+		esac
+	else
+		return $def
+	fi
+	done
+}
+
+	echo "client information for $CL_CONFIG will be deleted"
+	if yesno "Do you agree? yes or no [n] " 1 ; then
+		echo "Clearing"
+	else
+		echo "Aborted" && exit
+	fi
+	cd pool && rm -rf $CL_CONFIG
Index: dlkit2/sv/gensh-client.sub
diff -u /dev/null dlkit2/sv/gensh-client.sub:1.1.2.1
--- /dev/null	Wed Aug 23 00:57:26 2006
+++ dlkit2/sv/gensh-client.sub	Wed Aug 23 00:57:26 2006
@@ -0,0 +1,27 @@
+#!/bin/sh
+# -*- shell-script -*-
+# gensh-client.sub - generate maintenance script for the specified client.
+#
+# Copyright (c) 2006 SAWADA Keiji <card_capto****@users*****>
+# Copyright (c) 2005-2006 teelime <teeli****@users*****>
+#
+# This program is free software and has two license options; GNU
+# General Public License, or Common Development and Distribution
+# License.  You can and must select one when you redistribute and/or
+# modify this program.  Whatever you choose, this software comes with
+# absolutely no warranty.
+
+set -eu
+
+echon() {
+    printf "%s" "$@"
+}
+
+echo "generating..."
+cat > pool/maintenance-$CL_CONFIG.sh << EOF
+#!/bin/sh
+echo "Synchronizing boot_archive for postinstallation..."
+cp -p $SV_FIN_ROOT/platform/i86pc/boot_archive \
+$SV_PXEBOOTDIR/boot_archive.${CL_NAME}
+EOF
+echo "./pool/maintenance-$CL_CONFIG.sh is here."


dl-x86solaris-devel メーリングリストの案内
Back to archive index