Class: ChefBackup::Strategy::EbsBackup

Inherits:
TarBackup
  • Object
show all
Defined in:
lib/chef_backup/strategy/backup/ebs.rb

Overview

ChefBackup::Ebs class. To be used when/if Enterprise Chef ever supports EBS natively

Constant Summary

Constants inherited from TarBackup

TarBackup::DEFAULT_STATEFUL_SERVICES

Constants included from Helpers

Helpers::DEFAULT_PG_OPTIONS, Helpers::SERVER_ADD_ONS

Instance Attribute Summary

Attributes inherited from TarBackup

#backup_time

Instance Method Summary collapse

Methods inherited from TarBackup

#add_ha_services, #ask_to_go_offline, #chpst, #config_directories, #config_only?, #create_tarball, #data_map, #dump_db, #export_dir, #export_filename, #export_tarball, #external_pg?, #initialize, #manifest, #not_implemented, #offline_permission_granted?, #pg_dump?, #pg_dumpall, #populate_data_map, #populate_versions, #project_names, #service_enabled?, #stateful_services, #write_manifest

Methods included from Helpers

#addon_install_dir, #all_services, #backend?, #base_config_dir, #base_install_dir, #chpst, #cleanup, #config, #config_base, #ctl_command, #database_name, #disabled_services, #enabled_addons, #enabled_services, #ensure_file!, #frontend?, #ha?, #log, #marketplace?, #online?, #pg_options, #pgsql, #project_name, #reconfigure_add_ons, #reconfigure_marketplace, #restart_add_ons, #restart_chef_server, #running_filepath, #service_config, #service_enabled?, #shell_out, #shell_out!, #shell_timeout, #standalone?, #start_chef_server, #start_service, #stop_chef_server, #stop_service, #strategy, #tier?, #tmp_dir, #topology, #version_from_manifest_file

Constructor Details

This class inherits a constructor from ChefBackup::Strategy::TarBackup

Instance Method Details

#backupObject

  • ebs

    • Verify AWS credentials exist

    • Create backup manifest

    • Create backup dir on ebs volume

    • Copy /etc/opscode and manifest onto ebs volume

    • Take EBS snapshot



10
11
12
13
14
15
16
17
18
# File 'lib/chef_backup/strategy/backup/ebs.rb', line 10

def backup
  ensure_tmp_dir
  verify_ebs
  dump_db if pg_dump?
  create_manifest
  copy_opscode_config
  take_ebs_snapshot
  cleanup
end

#copy_opscode_configObject



24
# File 'lib/chef_backup/strategy/backup/ebs.rb', line 24

def copy_opscode_config; end

#take_ebs_snapshotObject



22
# File 'lib/chef_backup/strategy/backup/ebs.rb', line 22

def take_ebs_snapshot; end

#verify_ebsObject



20
# File 'lib/chef_backup/strategy/backup/ebs.rb', line 20

def verify_ebs; end