Class: Boothby::Toolbox
- Inherits:
-
Object
- Object
- Boothby::Toolbox
- Defined in:
- lib/boothby/maintenance.rb
Class Attribute Summary collapse
-
.root ⇒ Object
writeonly
Sets the attribute root.
Class Method Summary collapse
Class Attribute Details
.root=(value) ⇒ Object (writeonly)
Sets the attribute root
9 10 11 |
# File 'lib/boothby/maintenance.rb', line 9 def root=(value) @root = value end |
Class Method Details
.setup_application ⇒ Object
12 13 14 15 16 17 18 19 20 |
# File 'lib/boothby/maintenance.rb', line 12 def self.setup_application FileUtils.chdir(app_dir) do copy_example_files install_dependencies rake_task('db:prepare', 'db:test:prepare', label: 'Preparing database') rake_task('log:clear', 'tmp:clear', label: 'Cleaning old files') rake_task('restart', label: 'Restarting application server') end end |
.update_application ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'lib/boothby/maintenance.rb', line 22 def self.update_application FileUtils.chdir(app_dir) do copy_example_files install_dependencies rake_task('db:migrate', label: 'Updating database') rake_task('log:clear', 'tmp:clear', label: 'Cleaning old files') rake_task('restart', label: 'Restarting application server') end end |
.upgrade_application ⇒ Object
32 33 34 35 36 37 38 39 40 |
# File 'lib/boothby/maintenance.rb', line 32 def self.upgrade_application FileUtils.chdir(app_dir) do copy_example_files install_dependencies rake_task('db:migrate', label: 'Updating database') rake_task('log:clear', 'tmp:clear', label: 'Cleaning old files') rake_task('restart', label: 'Restarting application server') end end |