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-test-again-1.6.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-test-me-1.10.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-parser-fix-1.6.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.10.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.9.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.8.0.20130114204828 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.8.0.20130111070250 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.8.0.20130109172219 lib/fog/linode/requests/compute/stackscript_list.rb
ey-vendored-backup-3.0.27 vendor/gems/fog/lib/fog/linode/requests/compute/stackscript_list.rb
fog-sgonyea-1.8.1 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.8.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-maestrodev-1.7.0.20121114190951 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.7.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.6.0 lib/fog/linode/requests/compute/stackscript_list.rb
fog-1.5.0 lib/fog/linode/requests/compute/stackscript_list.rb
rackspace-fog-1.4.2 lib/rackspace-fog/linode/requests/compute/stackscript_list.rb
fog-1.4.0 lib/fog/linode/requests/compute/stackscript_list.rb
brightbox-cli-0.18.1 lib/brightbox-cli/vendor/fog/lib/fog/linode/requests/compute/stackscript_list.rb
michiels-fog-1.3.1 lib/fog/linode/requests/compute/stackscript_list.rb
ftl-0.2.0 vendor/bundle/gems/fog-1.3.1/lib/fog/linode/requests/compute/stackscript_list.rb