djangosnippets.org: Latest snippets tagged with 'admin-user'http://djangosnippets.org/tags/admin-user/2010-01-18T14:59:52.432985-06:00Auto-create Django admin user during syncdb
2010-01-18T14:59:52.432985-06:00staticohttp://djangosnippets.org/snippets/1875/<p>This avoids the frustrating step of having to set up a new admin user every time you re-initialize your database.</p>
<p>Put this in any <code>models</code> module. In this example I use <code>common.models</code>.</p>
<p>Adapted from http://stackoverflow.com/questions/1466827/</p>
Freely redistributable