Compare commits
	
		
			2 Commits
		
	
	
		
			8109ef4b1c
			...
			6414b290fa
		
	
	| Author | SHA1 | Date | |
|---|---|---|---|
|  | 6414b290fa | ||
|  | ba4a3e9fef | 
| @@ -114,7 +114,7 @@ clones are destroyed. Obviously this is the most dangerous operation of the bunc | ||||
| of the lab is that the VMs can be re-created off of a stable base image and a generated build. | ||||
|  | ||||
| ``` | ||||
| lab:~/src/lab$ LAB=0 ./destroy       ## remove VMs and ZFS clones on hvn0.lab.ipng.ch | ||||
| lab:~/src/lab$ LAB=0 ./command destroy       ## remove VMs and ZFS clones on hvn0.lab.ipng.ch | ||||
| ``` | ||||
|  | ||||
| ### Create | ||||
| @@ -129,7 +129,7 @@ Typically, it's necessary to destroy/create, only when the build or the base ima | ||||
| the lab can be brought back into a _factory default_ state by rolling back to the `pristine` snapshot. | ||||
|  | ||||
| ``` | ||||
| lab:~/src/lab$ LAB=0 ./create        ## create ZFS 'pristine' snapshots and start VMs | ||||
| lab:~/src/lab$ LAB=0 ./create                 ## create ZFS clones, copy in the build | ||||
| ``` | ||||
|  | ||||
| ### Pristine | ||||
| @@ -140,6 +140,7 @@ brought back into a default state by rolling back the disks to the `pristine` sn | ||||
| the virtual machines. | ||||
|  | ||||
| ``` | ||||
| lab:~/src/lab$ LAB=0 ./pristine      ## return the lab to the latest 'pristine' snapshot | ||||
| lab:~/src/lab$ LAB=0 ./vishall start ## Start the VMs | ||||
| lab:~/src/lab$ LAB=0 ./command start         ## Start the VMs | ||||
| lab:~/src/lab$ LAB=0 ./command shutdown      ## Start the VMs | ||||
| lab:~/src/lab$ LAB=0 ./command pristine      ## return the lab to the latest 'pristine' snapshot | ||||
| ``` | ||||
|   | ||||
							
								
								
									
										10
									
								
								command
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								command
									
									
									
									
									
								
							| @@ -2,11 +2,6 @@ | ||||
| BUILD=${BUILD:=default} | ||||
| LAB=${LAB:=0} | ||||
|  | ||||
| [ -r .lock${LAB} ] && { | ||||
|   echo "Lock file for LAB${LAB}, bailing" | ||||
|   exit | ||||
| } | ||||
|  | ||||
| ## Do not touch below this line | ||||
| LABDIR=/var/lab | ||||
| STAGING=$LABDIR/staging | ||||
| @@ -18,6 +13,11 @@ CMD=$1 | ||||
|   exit | ||||
| } | ||||
|  | ||||
| [ -r .lock${LAB} ] && { | ||||
|   echo "Lock file for LAB${LAB}, bailing" | ||||
|   exit | ||||
| } | ||||
|  | ||||
| VMS=$(ls -1 build/${BUILD}/${HVN}/) | ||||
|  | ||||
| for VM in $VMS; do | ||||
|   | ||||
		Reference in New Issue
	
	Block a user