Class: Brut::CLI::Apps::Deploy::DeployConfig::ProcessDescription
- Inherits:
-
Object
- Object
- Brut::CLI::Apps::Deploy::DeployConfig::ProcessDescription
- Defined in:
- lib/brut/cli/apps/deploy/deploy_config.rb
Overview
Describes a process you wish to run in production.
Instance Attribute Summary collapse
-
#cmd ⇒ Object
readonly
Returns the value of attribute cmd.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #cmd_directive ⇒ Object
-
#initialize(name:, cmd:) ⇒ ProcessDescription
constructor
A new instance of ProcessDescription.
Constructor Details
#initialize(name:, cmd:) ⇒ ProcessDescription
Returns a new instance of ProcessDescription.
52 53 54 55 |
# File 'lib/brut/cli/apps/deploy/deploy_config.rb', line 52 def initialize(name:, cmd:) @name = name @cmd = Array(cmd) end |
Instance Attribute Details
#cmd ⇒ Object (readonly)
Returns the value of attribute cmd.
50 51 52 |
# File 'lib/brut/cli/apps/deploy/deploy_config.rb', line 50 def cmd @cmd end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
50 51 52 |
# File 'lib/brut/cli/apps/deploy/deploy_config.rb', line 50 def name @name end |
Instance Method Details
#cmd_directive ⇒ Object
57 58 59 |
# File 'lib/brut/cli/apps/deploy/deploy_config.rb', line 57 def cmd_directive "CMD [ " + @cmd.map { "\"#{it}\"" }.join(", ") + " ]" end |