Sha256: 02f15199c755cc39de77b689d1221e84905a22c9d4ae70cc53e870215a05514f
Contents?: true
Size: 1009 Bytes
Versions: 25
Compression:
Stored size: 1009 Bytes
Contents
module Fog module Compute class AWS class Real require 'fog/aws/parsers/compute/start_stop_instances' # Stop specified instance # # ==== Parameters # * instance_id<~Array> - Id of instance to start # # ==== Returns # * response<~Excon::Response>: # * body<~Hash>: # * 'requestId'<~String> - Id of request # * TODO: fill in the blanks # # {Amazon API Reference}[http://docs.amazonwebservices.com/AWSEC2/latest/APIReference/ApiReference-query-StopInstances.html] def stop_instances(instance_id, force = false) params = Fog::AWS.indexed_param('InstanceId', instance_id) params.merge!('Force' => 'true') if force request({ 'Action' => 'StopInstances', :idempotent => true, :parser => Fog::Parsers::Compute::AWS::StartStopInstances.new }.merge!(params)) end end end end end
Version data entries
25 entries across 25 versions & 7 rubygems