class Deploy::Configuration
Attributes
account[RW]
api_key[RW]
project[RW]
username[RW]
websocket_hostname[W]
Public Class Methods
from_file(path)
click to toggle source
# File lib/deploy/configuration.rb, line 10 def self.from_file(path) file_contents = File.read(path) parsed_contents = JSON.parse(file_contents) self.new.tap do |config| config.account = parsed_contents['account'] config.username = parsed_contents['username'] config.api_key = parsed_contents['api_key'] config.project = parsed_contents['project'] config.websocket_hostname = parsed_contents['websocket_hostname'] end end
Public Instance Methods
websocket_hostname()
click to toggle source
# File lib/deploy/configuration.rb, line 6 def websocket_hostname @websocket_hostname || 'wss://websocket.deployhq.com' end