Class: Docker::API::Connection
- Inherits:
-
Object
- Object
- Docker::API::Connection
- Defined in:
- lib/docker/api/connection.rb
Overview
Connection class.
Instance Attribute Summary collapse
-
#excon ⇒ Object
readonly
Returns the value of attribute excon.
Instance Method Summary collapse
-
#initialize(url = nil, params = {}) ⇒ Connection
constructor
Create an Excon connection.
Constructor Details
#initialize(url = nil, params = {}) ⇒ Connection
Create an Excon connection.
11 12 13 14 |
# File 'lib/docker/api/connection.rb', line 11 def initialize url = nil, params = {} return @excon = Excon.new('unix:///', params.merge({socket: '/var/run/docker.sock'})) unless url @excon = Excon.new(url, params) end |
Instance Attribute Details
#excon ⇒ Object (readonly)
Returns the value of attribute excon.
4 5 6 |
# File 'lib/docker/api/connection.rb', line 4 def excon @excon end |