Sha256: ff262f60a1ca0f60ac5deb7adb3ea56ef8f256e855ff28fd36bf984f53555a49

Contents?: true

Size: 829 Bytes

Versions: 109

Compression:

Stored size: 829 Bytes

Contents

module Fog
  module Compute
    class Linode
      class Real

        # Get available stack scripts
        #
        # ==== Parameters
        # * scriptId<~Integer>: id to limit results to
        #
        # ==== Returns
        # * response<~Excon::Response>:
        #   * body<~Array>:
        # TODO: docs        
        def stackscript_list(script_id=nil)
          options = {}
          if script_id
            options.merge!(:stackScriptID => script_id)
          end          
          result = request(
            :expects  => 200,
            :method   => 'GET',
            :query    => { :api_action => 'stackscript.list' }.merge!(options)
          )
          result.body['DATA'].each { |r| r['DISTRIBUTIONIDLIST'] = r['DISTRIBUTIONIDLIST'].to_s }
          result
        end

      end
    end
  end
end

Version data entries

109 entries across 109 versions & 19 rubygems

Version Path
fog-maestrodev-1.18.0.20131205181604 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131127194823 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131126183714 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131126122111 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131125111730 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131125083406 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131123105121 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131122203507 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131121075022 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131118164830 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131115184302 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131114200144 lib/fog/linode/requests/compute/stackscript_list.rb
gapinc-fog-1.12.1.2.1 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131112185232 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.18.0.20131111203459 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.18.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.17.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.16.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.15.0.20130927082724 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.15.0.20130829165835 lib/fog/linode/requests/compute/stackscript_list.rb