Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,23 @@ Start Rails:
bin/rails server
```

## Restore a production dump

To replace the development database with a production SQL dump:

```bash
bin/rails db:drop db:create

gzip -dc ../registry-YYMMDD.sql.gz \
| sed 's/OWNER TO registry;/OWNER TO registry_test;/g' \
| bin/rails db

bin/rails db:migrate
```

The ownership replacement is needed because production objects belong to the
`registry` Postgres role, while development uses `registry_test`.

## Configuration

### External API's
Expand Down
Loading