Class: DPL::Provider::DotCloud
- Inherits:
-
Provider
- Object
- Provider
- DPL::Provider::DotCloud
- Defined in:
- lib/dpl/provider/dot_cloud.rb
Instance Method Summary collapse
- #check_app ⇒ Object
- #check_auth ⇒ Object
- #needs_key? ⇒ Boolean
- #push_app ⇒ Object
- #run(command) ⇒ Object
Instance Method Details
#check_app ⇒ Object
11 12 13 |
# File 'lib/dpl/provider/dot_cloud.rb', line 11 def check_app context.shell "dotcloud connect #{option(:app)}" end |
#check_auth ⇒ Object
7 8 9 |
# File 'lib/dpl/provider/dot_cloud.rb', line 7 def check_auth context.shell "echo #{option(:api_key)} | dotcloud setup --api-key" end |
#needs_key? ⇒ Boolean
15 16 17 |
# File 'lib/dpl/provider/dot_cloud.rb', line 15 def needs_key? false end |
#push_app ⇒ Object
19 20 21 |
# File 'lib/dpl/provider/dot_cloud.rb', line 19 def push_app context.shell "dotcloud push #{option(:app)}" end |
#run(command) ⇒ Object
23 24 25 26 |
# File 'lib/dpl/provider/dot_cloud.rb', line 23 def run(command) service = [:instance] || [:service] || 'www' context.shell "dotcloud -A #{option(:app)} #{service} #{command}" end |