Skip to content

Instantly share code, notes, and snippets.

@maciejjankowski
Created March 24, 2021 12:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maciejjankowski/c1ab718ec7bdf14090f340b519e3cbcd to your computer and use it in GitHub Desktop.
Save maciejjankowski/c1ab718ec7bdf14090f340b519e3cbcd to your computer and use it in GitHub Desktop.
Restore pg_dump data
docker cp db_backup_file docker_hash:/tmp/db_backup_file
pg_restore --no-privileges \
--no-owner \
--superuser=postgres \
--disable-triggers \
--clean \
-d db_name \
/tmp/db_backup_file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment