Skip to content

ilya90906767/djangoExperiment

 
 

Repository files navigation

Django Pet Project

Get Started

Generate Django secrete jey

from django.core.management.utils import get_random_secret_key

get_random_secret_key()

Create .env file:

Here below an example .env file for development purposes:

DEBUG=1 # Don't use 1 (True) in the production environment!
SECRET_KEY=''
DJANGO_ALLOWED_HOSTS='localhost 127.0.0.1 [::1]'
SQL_ENGINE=django.db.backends.postgresql_psycopg2
DB_USER=''
DB_PASSWORD=''
DB_NAME=''
CONTACT_EMAIL_ADDRESS=''

Deploy

bash deploy.sh

Database Backups

Create a database backup:

docker compose exec database pg_dump --format=custom > backup.pgdump

Restore a database backup:

docker compose exec database \
    pg_restore --clean --dbname $DB_NAME -U $DB_USER backup.pgdump

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 49.0%
  • HTML 23.9%
  • JavaScript 23.9%
  • CSS 1.7%
  • Other 1.5%