 05530caf2c
			
		
	
	05530caf2c
	
	
	
		
			
			The enable_service() and disable_service() functions in https://review.openstack.org/9407 require the functions file be sourced before stackrc. * exercise.sh * samples/local.sh (this will require manual addition to the user's local.sh if they based it on the sample) * tools/build_bm.sh Change-Id: I1bed687867e870bef5748289d712376435a776af
		
			
				
	
	
		
			39 lines
		
	
	
		
			849 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
			
		
		
	
	
			39 lines
		
	
	
		
			849 B
		
	
	
	
		
			Bash
		
	
	
		
			Executable File
		
	
	
	
	
| #!/usr/bin/env bash
 | |
| 
 | |
| # **build_bm.sh**
 | |
| 
 | |
| # Build an OpenStack install on a bare metal machine.
 | |
| set +x
 | |
| 
 | |
| # Keep track of the current directory
 | |
| TOOLS_DIR=$(cd $(dirname "$0") && pwd)
 | |
| TOP_DIR=$(cd $TOOLS_DIR/..; pwd)
 | |
| 
 | |
| # Import common functions
 | |
| source $TOP_DIR/functions
 | |
| 
 | |
| # Source params
 | |
| source ./stackrc
 | |
| 
 | |
| # Param string to pass to stack.sh.  Like "EC2_DMZ_HOST=192.168.1.1 MYSQL_USER=nova"
 | |
| STACKSH_PARAMS=${STACKSH_PARAMS:-}
 | |
| 
 | |
| # Option to use the version of devstack on which we are currently working
 | |
| USE_CURRENT_DEVSTACK=${USE_CURRENT_DEVSTACK:-1}
 | |
| 
 | |
| # Configure the runner
 | |
| RUN_SH=`mktemp`
 | |
| cat > $RUN_SH <<EOF
 | |
| #!/usr/bin/env bash
 | |
| # Install and run stack.sh
 | |
| cd devstack
 | |
| $STACKSH_PARAMS ./stack.sh
 | |
| EOF
 | |
| 
 | |
| # Make the run.sh executable
 | |
| chmod 755 $RUN_SH
 | |
| 
 | |
| scp -r . root@$CONTAINER_IP:devstack
 | |
| scp $RUN_SH root@$CONTAINER_IP:$RUN_SH
 | |
| ssh root@$CONTAINER_IP $RUN_SH
 |