Module: Inploy::Servers::Godlike
- Defined in:
- lib/inploy/servers/godlike.rb,
lib/inploy/servers/version.rb
Constant Summary collapse
- VERSION =
"0.1.0"
Instance Attribute Summary collapse
-
#god_group ⇒ Object
Returns the value of attribute god_group.
Instance Method Summary collapse
Instance Attribute Details
#god_group ⇒ Object
Returns the value of attribute god_group.
4 5 6 |
# File 'lib/inploy/servers/godlike.rb', line 4 def god_group @god_group end |
Instance Method Details
#god_cmd ⇒ Object
6 7 8 |
# File 'lib/inploy/servers/godlike.rb', line 6 def god_cmd "god -p #{god_group}" end |
#restart_server ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/inploy/servers/godlike.rb', line 14 def restart_server start_server Dir.glob('config/*.god').each do |conf| run "#{god_cmd} load #{conf}" end run "#{god_cmd} restart #{god_group}" end |
#start_server ⇒ Object
10 11 12 |
# File 'lib/inploy/servers/godlike.rb', line 10 def start_server run "#{god_cmd} status > /dev/null || #{god_cmd}" end |