mirror of
				https://github.com/xcat2/xcat-core.git
				synced 2025-11-04 05:12:30 +00:00 
			
		
		
		
	git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@1561 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
		
			
				
	
	
		
			45 lines
		
	
	
		
			703 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			45 lines
		
	
	
		
			703 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
      <chroot-scripts config:type="list">
 | 
						|
        <script>
 | 
						|
          <filename>boot.sh</filename>
 | 
						|
          <interpreter>shell</interpreter>
 | 
						|
          <source>
 | 
						|
 | 
						|
<![CDATA[
 | 
						|
#!/bin/sh
 | 
						|
 | 
						|
AWK=`find / -name awk | head -1`
 | 
						|
#old awk /mounts/instsys/bin/awk -f
 | 
						|
 | 
						|
cat >/tmp/updateflag.awk <<EOF
 | 
						|
#!$AWK -f
 | 
						|
 | 
						|
BEGIN {
 | 
						|
	xcatdport = #TABLE:site:key=xcatiport:value#
 | 
						|
	xcatdhost = "#XCATVAR:XCATMASTER#"
 | 
						|
 | 
						|
	ns = "/inet/tcp/0/" xcatdhost "/" xcatdport
 | 
						|
 | 
						|
	while(1) {
 | 
						|
		if((ns |& getline) > 0)
 | 
						|
			print \$0
 | 
						|
 | 
						|
		if(\$0 == "ready")
 | 
						|
			print "next" |& ns
 | 
						|
		if(\$0 == "done")
 | 
						|
			break
 | 
						|
	}
 | 
						|
 | 
						|
	close(ns)
 | 
						|
 | 
						|
	exit 0
 | 
						|
}
 | 
						|
EOF
 | 
						|
 | 
						|
chmod 755 /tmp/updateflag.awk
 | 
						|
/tmp/updateflag.awk
 | 
						|
]]>
 | 
						|
 | 
						|
          </source>
 | 
						|
        </script>
 | 
						|
      </chroot-scripts>
 |