From 8a9fdecb25ef06775d25cd8b6a387a7241aab4e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luiz=20Ot=C3=A1vio?= Date: Thu, 27 Apr 2023 13:51:25 -0300 Subject: [PATCH] =?UTF-8?q?Sobre=20os=20arquivos=20est=C3=A1ticos,=20DEBUG?= =?UTF-8?q?=20e=20ALLOWED=5FHOSTS?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitignore | 1 + aula207_ola_django/project/settings.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index 29de9ce..d639fa6 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,7 @@ __localcode chromedriver mysql_206 .env +aula207_ola_django/static_files # Byte-compiled / optimized / DLL files __pycache__/ diff --git a/aula207_ola_django/project/settings.py b/aula207_ola_django/project/settings.py index 79ee056..04009f6 100644 --- a/aula207_ola_django/project/settings.py +++ b/aula207_ola_django/project/settings.py @@ -123,6 +123,8 @@ STATIC_URL = 'static/' STATICFILES_DIRS = [ BASE_DIR / 'base' / 'static' ] +# https://whitenoise.readthedocs.io/en/latest/ +STATIC_ROOT = BASE_DIR / 'static_files' # Default primary key field type # https://docs.djangoproject.com/en/4.2/ref/settings/#default-auto-field