/quiz

Yet another Quiz app.

Primary LanguagePythonMIT LicenseMIT

License MIT

Set up

Locally

Production

  • Install Docker
  • Install Docker Compose
  • Set the environment variables
    • MYSQL_ROOT_PASSWORD
    • MYSQL_DATABASE
    • MYSQL_USER
    • MYSQL_PASSWORD
  • Run docker-compose -f docker-compose-prod.yml up -d
  • Finally, go to http://server_ip_address

Locally without using Docker

  • Install Django
  • Go to app/app.
  • Run python manage.py runserver

Usage

django-admin and manage.py

To use django-admin and manage.py, run

docker-compose exec --user=cpuser app bash

This will take you inside the app container and you will be able to use both use django-admin and manage.py and the --user=cpuser ensures that the files are not created as root on the host.

The Django-Extensions have also been added.

python manage.py show_urls

So commands like show_urls are available.