Class: Dip::Commands::DNS::Up
- Inherits:
-
Dip::Command
- Object
- Dip::Command
- Dip::Commands::DNS::Up
- Defined in:
- lib/dip/commands/dns.rb
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(name:, socket:, net:, publish:, image:, domain:) ⇒ Up
constructor
A new instance of Up.
Methods inherited from Dip::Command
Constructor Details
#initialize(name:, socket:, net:, publish:, image:, domain:) ⇒ Up
Returns a new instance of Up.
10 11 12 13 14 15 16 17 |
# File 'lib/dip/commands/dns.rb', line 10 def initialize(name:, socket:, net:, publish:, image:, domain:) @name = name @socket = socket @net = net @publish = publish @image = image @domain = domain end |
Instance Method Details
#execute ⇒ Object
19 20 21 22 |
# File 'lib/dip/commands/dns.rb', line 19 def execute exec_subprocess("docker", "network create #{@net}", panic: false, err: File::NULL) exec_subprocess("docker", "run #{container_args} #{@image} --domain=#{@domain}") end |