Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

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?

like image 389
z3a Avatar asked Mar 06 '09 06:03

z3a


1 Answers

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
like image 58
Van Gale Avatar answered Nov 12 '22 09:11

Van Gale