Sha256: 3aa73e2629583828fee473fd137851f06514e17320f9d60c4c04eadc3cbb6b3d
Contents?: true
Size: 671 Bytes
Versions: 11
Compression:
Stored size: 671 Bytes
Contents
require 'vagrant-conoha/action/abstract_action' module VagrantPlugins module ConoHa module Action class Suspend < AbstractAction def initialize(app, _env) @app = app @logger = Log4r::Logger.new('vagrant_openstack::action::suspend_server') end def execute(env) if env[:machine].id @logger.info "Saving VM #{env[:machine].id} state and suspending execution..." env[:ui].info I18n.t('vagrant.actions.vm.suspend.suspending') env[:openstack_client].nova.suspend_server(env, env[:machine].id) end @app.call(env) end end end end end
Version data entries
11 entries across 11 versions & 1 rubygems