Class: Bard::Backup::Controller
- Inherits:
-
Struct
- Object
- Struct
- Bard::Backup::Controller
- Defined in:
- lib/bard/backup/controller.rb
Instance Attribute Summary collapse
-
#dumper ⇒ Object
Returns the value of attribute dumper.
-
#now ⇒ Object
Returns the value of attribute now.
-
#s3_dir ⇒ Object
Returns the value of attribute s3_dir.
Instance Method Summary collapse
Instance Attribute Details
#dumper ⇒ Object
Returns the value of attribute dumper
3 4 5 |
# File 'lib/bard/backup/controller.rb', line 3 def dumper @dumper end |
#now ⇒ Object
Returns the value of attribute now
3 4 5 |
# File 'lib/bard/backup/controller.rb', line 3 def now @now end |
#s3_dir ⇒ Object
Returns the value of attribute s3_dir
3 4 5 |
# File 'lib/bard/backup/controller.rb', line 3 def s3_dir @s3_dir end |
Instance Method Details
#call ⇒ Object
4 5 6 7 8 9 |
# File 'lib/bard/backup/controller.rb', line 4 def call filename = "#{now.iso8601}.sql.gz" path = "/tmp/#{filename}" dumper.dump path s3_dir.put path end |