Module: AnotherBrick::Configuration

Included in:
AnotherBrick
Defined in:
lib/another_brick/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#bricklayer_serverObject

Returns the value of attribute bricklayer_server.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def bricklayer_server
  @bricklayer_server
end

#bricklayer_triesObject

Returns the value of attribute bricklayer_tries.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def bricklayer_tries
  @bricklayer_tries
end

#deploy_serverObject

Returns the value of attribute deploy_server.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def deploy_server
  @deploy_server
end

#deploy_userObject

Returns the value of attribute deploy_user.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def deploy_user
  @deploy_user
end

#max_triesObject

Returns the value of attribute max_tries.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def max_tries
  @max_tries
end

#package_nameObject

Returns the value of attribute package_name.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def package_name
  @package_name
end

#tagObject

Returns the value of attribute tag.



3
4
5
# File 'lib/another_brick/configuration.rb', line 3

def tag
  @tag
end

Instance Method Details

#load_configuration(options = {}) ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
# File 'lib/another_brick/configuration.rb', line 6

def load_configuration(options = {})
  self.bricklayer_server = options[:bricklayer]
  self.package_name      = options[:name]
  self.deploy_server     = options[:server]
  self.deploy_user       = options[:user]
  self.max_tries         = options[:max_tries].to_i
  self.bricklayer_tries  = options[:bricklayer_tries].to_i
  self.tag               = options[:tag]
  @verbose               = options[:verbose]
  RestClient.proxy       = ENV['http_proxy']
end

#verbose?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/another_brick/configuration.rb', line 18

def verbose?
  @verbose
end