Class: Ipfs::Connection::IpfsConfig
- Defined in:
- lib/ruby-ipfs-http-client/connection/ipfs_config.rb
Constant Summary collapse
- CONFIG_FILEPATH =
"#{ENV['HOME']}/.ipfs/config"
Constants inherited from Base
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize ⇒ IpfsConfig
constructor
A new instance of IpfsConfig.
Methods inherited from Base
#build_uri, #make_persistent, #up?
Constructor Details
#initialize ⇒ IpfsConfig
Returns a new instance of IpfsConfig.
8 9 10 11 12 13 |
# File 'lib/ruby-ipfs-http-client/connection/ipfs_config.rb', line 8 def initialize parse_config.tap { |location| @host = location[:host] @port = location[:port] } end |