Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
W
Widget The Expendables
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jimson Paulo Layacan
Widget The Expendables
Commits
163f6cd3
Commit
163f6cd3
authored
Mar 03, 2022
by
JP Layacan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Configured settings.py to safely store the secret key in a .env file
parent
ba0b4bec
Pipeline
#2241
failed with stages
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
1 deletion
+7
-1
.env
Widget (The Expendables)/.env
+1
-0
settings.cpython-310.pyc
... Expendables)/Widget/__pycache__/settings.cpython-310.pyc
+0
-0
settings.py
Widget (The Expendables)/Widget/settings.py
+6
-1
urls.cpython-310.pyc
...he Expendables)/homepage/__pycache__/urls.cpython-310.pyc
+0
-0
No files found.
Widget (The Expendables)/.env
0 → 100644
View file @
163f6cd3
SECRET_KEY='django-insecure-!#35*x&fl+k@d*hai6n%_q75k6qqwui#67#)da%xh%m6+xo&vd'
Widget (The Expendables)/Widget/__pycache__/settings.cpython-310.pyc
View file @
163f6cd3
No preview for this file type
Widget (The Expendables)/Widget/settings.py
View file @
163f6cd3
...
...
@@ -11,6 +11,11 @@ https://docs.djangoproject.com/en/3.2/ref/settings/
"""
from
pathlib
import
Path
from
dotenv
import
load_dotenv
import
os
load_dotenv
()
# Build paths inside the project like this: BASE_DIR / 'subdir'.
BASE_DIR
=
Path
(
__file__
)
.
resolve
()
.
parent
.
parent
...
...
@@ -20,7 +25,7 @@ BASE_DIR = Path(__file__).resolve().parent.parent
# See https://docs.djangoproject.com/en/3.2/howto/deployment/checklist/
# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY
=
'django-insecure-!#35*x&fl+k@d*hai6n
%
_q75k6qqwui#67#)da
%
xh
%
m6+xo&vd'
SECRET_KEY
=
os
.
getenv
(
'SECRET_KEY'
)
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG
=
True
...
...
Widget (The Expendables)/homepage/__pycache__/urls.cpython-310.pyc
View file @
163f6cd3
No preview for this file type
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment