Class: Indocker::DockerDirectives::Cmd
- Inherits:
-
Base
- Object
- Indocker::Directives::Base
- Base
- Indocker::DockerDirectives::Cmd
- Defined in:
- lib/indocker/directives/docker_directives/cmd.rb
Instance Attribute Summary collapse
-
#command ⇒ Object
readonly
Returns the value of attribute command.
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(command) ⇒ Cmd
constructor
A new instance of Cmd.
- #to_s ⇒ Object
- #type ⇒ Object
Methods inherited from Indocker::Directives::Base
#build_directive?, #container_directive?, #partial?, #prepare_directive?
Constructor Details
#initialize(command) ⇒ Cmd
Returns a new instance of Cmd.
4 5 6 |
# File 'lib/indocker/directives/docker_directives/cmd.rb', line 4 def initialize(command) @command = command end |
Instance Attribute Details
#command ⇒ Object (readonly)
Returns the value of attribute command.
2 3 4 |
# File 'lib/indocker/directives/docker_directives/cmd.rb', line 2 def command @command end |
Instance Method Details
#to_s ⇒ Object
8 9 10 |
# File 'lib/indocker/directives/docker_directives/cmd.rb', line 8 def to_s "#{type} #{command.inspect}" end |
#type ⇒ Object
12 13 14 |
# File 'lib/indocker/directives/docker_directives/cmd.rb', line 12 def type 'CMD' end |