Class: Vx::Builder::ScriptBuilder::Services
- Defined in:
- lib/vx/builder/script_builder/services.rb
Constant Summary collapse
- ALIASES =
{ 'rabbitmq' => 'rabbitmq-server' }
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
Methods inherited from Base
#deploy?, #do_after_deploy, #do_announce, #do_before_deploy, #do_before_install, #do_before_script, #do_cache_key, #do_cached_directories, #do_deploy_script, #do_init, #do_install, #do_script
Methods included from Helper::VxvmInstall
Methods included from Helper::TraceShCommand
Instance Method Details
#call(env) ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/vx/builder/script_builder/services.rb', line 11 def call(env) env.source.services.each do |srv| srv = ALIASES[srv] || srv env.init << trace_sh_command("sudo service #{srv} start") end unless env.source.services.empty? env.init << trace_sh_command("sleep 3") end app.call(env) end |