Class: Vx::Lib::Container::Docker::Spawner
- Inherits:
-
Struct
- Object
- Struct
- Vx::Lib::Container::Docker::Spawner
- Includes:
- Lib::Shell, Upload
- Defined in:
- lib/vx/lib/container/docker/spawner.rb
Instance Attribute Summary collapse
-
#container ⇒ Object
Returns the value of attribute container.
-
#ssh ⇒ Object
Returns the value of attribute ssh.
Instance Method Summary collapse
Methods included from Upload
Instance Attribute Details
#container ⇒ Object
Returns the value of attribute container
7 8 9 |
# File 'lib/vx/lib/container/docker/spawner.rb', line 7 def container @container end |
#ssh ⇒ Object
Returns the value of attribute ssh
7 8 9 |
# File 'lib/vx/lib/container/docker/spawner.rb', line 7 def ssh @ssh end |
Instance Method Details
#exec(script, &logger) ⇒ Object
12 13 14 15 |
# File 'lib/vx/lib/container/docker/spawner.rb', line 12 def exec(script, &logger) sh(:ssh, ssh).exec upload(script, "~/build.sh", mode: '0755', &logger) sh(:ssh, ssh).exec("~/build.sh", &logger) end |
#id ⇒ Object
17 18 19 |
# File 'lib/vx/lib/container/docker/spawner.rb', line 17 def id container.id end |