Class: KumoDockerCloud::Stack

Inherits:
Object
  • Object
show all
Defined in:
lib/kumo_dockercloud/stack.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(app_name, env_name, options = { contactable: true }) ⇒ Stack

Returns a new instance of Stack.



5
6
7
8
9
# File 'lib/kumo_dockercloud/stack.rb', line 5

def initialize(app_name, env_name, options = { contactable: true })
  @app_name = app_name
  @stack_name = "#{app_name}-#{env_name}"
  @options = options
end

Instance Attribute Details

#app_nameObject (readonly)

Returns the value of attribute app_name.



3
4
5
# File 'lib/kumo_dockercloud/stack.rb', line 3

def app_name
  @app_name
end

#optionsObject (readonly)

Returns the value of attribute options.



3
4
5
# File 'lib/kumo_dockercloud/stack.rb', line 3

def options
  @options
end

#stack_nameObject (readonly)

Returns the value of attribute stack_name.



3
4
5
# File 'lib/kumo_dockercloud/stack.rb', line 3

def stack_name
  @stack_name
end

Instance Method Details

#deploy(version) ⇒ Object



11
12
13
14
15
# File 'lib/kumo_dockercloud/stack.rb', line 11

def deploy(version)
  update_image(version)
  redeploy
  validate_deployment(version)
end