labs: make use of snapshot functionality

This changeset pushes some of the code from virtualbox.install_node
to the configuration files.

In doing so, the patch demonstrates how additional snapshots can be
configured just by editing config/scripts.*.

Implements: blueprint openstack-training-labs
Change-Id: I1f5f6d5aa3842da8fa94bd1a10a753bb80db023b
This commit is contained in:
Roger Luethi 2014-08-09 17:21:26 +02:00
parent 2d8e2be5a4
commit 6372b4e5e0
5 changed files with 11 additions and 5 deletions

View File

@ -1 +1,4 @@
# Scripts for compute node
scripts shutdown.sh
boot
snapshot "pre-installed"

View File

@ -2,3 +2,6 @@
scripts apt_install_mysql.sh
scripts setup_keystone.sh
scripts setup_glance.sh
scripts shutdown.sh
boot
snapshot "pre-installed"

View File

@ -1 +1,4 @@
# Scripts for network node
scripts shutdown.sh
boot
snapshot "pre-installed"

View File

@ -3,3 +3,5 @@ scripts etc_hosts.sh
osbash enable_vagrant_ssh_keys.sh
#osbash wait_debug.sh
scripts shutdown.sh
boot
snapshot "Network configured."

View File

@ -69,14 +69,9 @@ function vm_build_node {
autostart_and_rename osbash init_xxx_node.sh "init_${NODE_NAME}_node.sh"
autostart_from_config scripts.nodeinit_osbash
_vbox_boot_with_autostart "$NODE_NAME" "$VM_SSH_PORT"
vm_snapshot "$NODE_NAME" "network_configured"
#- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
autostart_reset
autostart_from_config "scripts.$NODE_NAME"
autostart scripts shutdown.sh
_vbox_boot_with_autostart "$NODE_NAME" "$VM_SSH_PORT"
vm_snapshot "$NODE_NAME" "pre-installed"
#- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
${WBATCH:-:} wbatch_end_file