Sha256: d30ffc6cc22c4bd47268c2cc8598d31214e0e1a55b92a1a0de7f68c65535001e
Contents?: true
Size: 708 Bytes
Versions: 8
Compression:
Stored size: 708 Bytes
Contents
require "log4r" module VagrantPlugins module OpenStack module Action # This reboots a running server, if there is one. class TakeSnapshot def initialize(app, env) @app = app @logger = Log4r::Logger.new("vagrant_openstack::action::take_snapshot") end def call(env) if env[:machine].id env[:ui].info(I18n.t("vagrant_openstack.snapshoting_server")) infos = env[:openstack_compute].get_server_details(env[:machine].id) env[:openstack_compute].create_image(env[:machine].id,env[:openstack_snapshot_name] || 'snapshot') end @app.call(env) end end end end end
Version data entries
8 entries across 8 versions & 2 rubygems