Class: Aptible::Api::Stack

Inherits:
Resource
  • Object
show all
Defined in:
lib/aptible/api/stack.rb

Instance Method Summary collapse

Methods inherited from Resource

#namespace, #root_url

Instance Method Details

#aws_instances_with_deprovisionableObject

This method is necessary because we need to include a query parameter when requesting aws_instances. Copied the important bits from github.com/aptible/aptible-resource/blob/4708fb80a6c21013de07c2779ffc4928cee37d4e/lib/aptible/resource/base.rb#L138



31
32
33
34
35
36
37
38
39
40
41
42
43
# File 'lib/aptible/api/stack.rb', line 31

def aws_instances_with_deprovisionable
  get unless loaded

  return unless links['aws_instances']

  param = 'include_deprovisionable=true'
  href = "#{links['aws_instances'].base_href}?#{param}"
  self.class.all(
    href: href,
    token: token,
    headers: headers
  )
end

#dns_layersObject



23
24
25
# File 'lib/aptible/api/stack.rb', line 23

def dns_layers
  stack_layers.reject! { |l| l.dns_name.blank? }
end