Class: Astrails::Safe::Pgdump
- Defined in:
- lib/astrails/safe/pgdump.rb
Instance Attribute Summary
Attributes inherited from Source
Attributes inherited from Stream
Instance Method Summary collapse
Methods inherited from Source
#backup, #filename, #initialize, #kind, #timestamp
Methods inherited from Stream
Constructor Details
This class inherits a constructor from Astrails::Safe::Source
Instance Method Details
#command ⇒ Object
5 6 7 8 9 10 11 12 |
# File 'lib/astrails/safe/pgdump.rb', line 5 def command if @config["password"] ENV['PGPASSWORD'] = @config["password"] else ENV['PGPASSWORD'] = nil end "pg_dump #{} #{postgres_username} #{postgres_host} #{postgres_port} #{@id}" end |
#extension ⇒ Object
14 |
# File 'lib/astrails/safe/pgdump.rb', line 14 def extension; '.sql'; end |