Sha256: 3cf8edca6c1807fef823cca58905dd7c8b5c00796e741e8410f066a482f839fb
Contents?: true
Size: 495 Bytes
Versions: 1
Compression:
Stored size: 495 Bytes
Contents
module Dbcp class PostgresDatabase < Database def export_command(snapshot_file) %W[export PGPASSWORD=#{password}].shelljoin + '; ' + %W[pg_dump --host #{host} --username #{username} --file #{snapshot_file.path} --format c #{database}].shelljoin end def import_command(snapshot_file) %W[export PGPASSWORD=#{password}].shelljoin + '; ' + %W[pg_restore --host #{host} --username #{username} --clean --dbname #{database} #{snapshot_file.path}].shelljoin end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dbcp-0.0.1 | lib/dbcp/databases/postgres_database.rb |