z3a
z3a

Reputation: 1004

Django flatpages backup?

I'm using flatpages in a site that I'm developing in a locally server. I need to backup the flatpage's data for use it in the final server. Does anyone know how to do it?

Upvotes: 13

Views: 1505

Answers (1)

Van Gale
Van Gale

Reputation: 43912

On your local server run this:

python manage.py dumpdata flatpages --indent=2 > backup.json

Then copy backup.json to your final server and load it with:

python manage.py loaddata backup.json

Upvotes: 19

Related Questions