From d241bba2b215c14f243417e6d8d567ad26392943 Mon Sep 17 00:00:00 2001 From: Stepan Date: Sat, 13 Dec 2025 16:10:07 +0100 Subject: [PATCH] deploy file --- manage.py | 22 ++++++++++++++++++++++ project/settings/prod.py | 11 ++++++++++- 2 files changed, 32 insertions(+), 1 deletion(-) create mode 100755 manage.py diff --git a/manage.py b/manage.py new file mode 100755 index 0000000..530913f --- /dev/null +++ b/manage.py @@ -0,0 +1,22 @@ +#!/usr/bin/env python +"""Django's command-line utility for administrative tasks.""" +import os +import sys + + +def main(): + """Run administrative tasks.""" + os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'project.settings.prod') + try: + from django.core.management import execute_from_command_line + except ImportError as exc: + raise ImportError( + "Couldn't import Django. Are you sure it's installed and " + "available on your PYTHONPATH environment variable? Did you " + "forget to activate a virtual environment?" + ) from exc + execute_from_command_line(sys.argv) + + +if __name__ == '__main__': + main() diff --git a/project/settings/prod.py b/project/settings/prod.py index a8d10f8..2c9c039 100644 --- a/project/settings/prod.py +++ b/project/settings/prod.py @@ -1,3 +1,12 @@ from .base import * -DEBUG = False \ No newline at end of file +ALLOWED_HOSTS = ['*'] + +DEBUG = False + +DATABASES = { + 'default': { + 'ENGINE': 'django.db.backends.sqlite3', + 'NAME': BASE_DIR / 'db.sqlite3', + } +}