Browse Source

Automatically load the Question fixture on every deployment

pull/160/head
Mike Olund 8 years ago
parent
commit
3ce68b365a
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      wsgi.py

+ 3
- 0
wsgi.py View File

@ -16,6 +16,9 @@ if not os.environ.get('OPENSHIFT_BUILD_NAMESPACE', False):
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "edivorce.settings.local")
else:
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "edivorce.settings.openshift")
# compress the static assets
execute_from_command_line(['manage.py', 'compress', '--force'])
# load the Question fixture
execute_from_command_line(['manage.py', 'loaddata', '/opt/app-root/src/edivorce/fixtures/Question.json'])
application = get_wsgi_application()

Loading…
Cancel
Save