Class: LuTze
- Inherits:
-
Object
- Object
- LuTze
- Defined in:
- lib/lu_tze.rb
Class Method Summary collapse
Instance Method Summary collapse
- #compress ⇒ Object
-
#initialize ⇒ LuTze
constructor
A new instance of LuTze.
- #save ⇒ Object
- #upload ⇒ Object
Constructor Details
#initialize ⇒ LuTze
Returns a new instance of LuTze.
8 9 10 |
# File 'lib/lu_tze.rb', line 8 def initialize save && compress end |
Class Method Details
Instance Method Details
#compress ⇒ Object
16 17 18 |
# File 'lib/lu_tze.rb', line 16 def compress system compress_command end |
#save ⇒ Object
12 13 14 |
# File 'lib/lu_tze.rb', line 12 def save system dump_command end |
#upload ⇒ Object
20 21 22 23 24 25 |
# File 'lib/lu_tze.rb', line 20 def upload file = File.new(compressed_file_name, 'r') RestClient.post 'http://historian.heroku.com/api/data_backups', :site_key => ENV['historian_key'], :backup => file end |