Skip to content

Commit

Permalink
test build 5
Browse files Browse the repository at this point in the history
  • Loading branch information
OlegGsk committed Sep 29, 2024
1 parent a7562be commit 9a7f6fe
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 2 deletions.
1 change: 1 addition & 0 deletions adaptive_hockey_federation/core/config/base_settings.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
from pathlib import Path
from re import DEBUG

import environ
from django.contrib.messages import constants as messages
Expand Down
2 changes: 1 addition & 1 deletion adaptive_hockey_federation/core/config/dev_settings.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from . base_settings import *
from .base_settings import *

ROOT_DIR = BASE_DIR.parent

Expand Down
18 changes: 17 additions & 1 deletion adaptive_hockey_federation/manage.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,28 @@

import os
import sys
import environ

from adaptive_hockey_federation.core.config.base_settings import BASE_DIR

env = environ.Env()


env.read_env(BASE_DIR.parent / ".env")

DEBUG = os.environ.get("DEBUG")


print(f"{DEBUG=}")

switch_prod_dev = {"True": "dev", "False": "prod"}
print(switch_prod_dev[str(DEBUG)])


def main():
"""Run administrative tasks."""
os.environ.setdefault("DJANGO_SETTINGS_MODULE",
"core.config.prod_settings")
f"core.config.{switch_prod_dev[str(DEBUG)]}_settings")
try:
from django.core.management import execute_from_command_line
except ImportError as exc:
Expand Down
1 change: 1 addition & 0 deletions requirements/production.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ click-repl==0.3.0 ; python_version >= "3.11" and python_version < "4.0"
click==8.1.7 ; python_version >= "3.11" and python_version < "4.0"
colorama==0.4.6 ; python_version >= "3.11" and python_version < "4.0" and (platform_system == "Windows" or sys_platform == "win32")
django-environ==0.11.2 ; python_version >= "3.11" and python_version < "4"
django-extensions==3.2.3 ; python_version >= "3.11" and python_version < "4.0"
django-phonenumber-field[phonenumbers]==7.3.0 ; python_version >= "3.11" and python_version < "4.0"
django==4.2.13 ; python_version >= "3.11" and python_version < "4.0"
djangorestframework==3.15.2 ; python_version >= "3.11" and python_version < "4.0"
Expand Down

0 comments on commit 9a7f6fe

Please sign in to comment.