Merge pull request #7 from mtyton/feature/production_preparation

Feature/production preparation
pull/2/head
mtyton 2023-05-16 20:05:42 +02:00 zatwierdzone przez GitHub
commit 69581ce53d
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 4AEE18F83AFDEB23
4 zmienionych plików z 32 dodań i 13 usunięć

Wyświetl plik

@ -93,7 +93,7 @@ import dj_database_url as db_url
DATABASES = {
"default": db_url.parse(
"postgres://comfy:password@db/comfy_shop"
os.environ.get("DATABASE_URL")
)
}

Wyświetl plik

@ -2,7 +2,10 @@ from .base import *
DEBUG = False
try:
from .local import *
except ImportError:
pass
SECRET_KEY = os.environ.get("SECRET_KEY")
ALLOWED_HOSTS = [
"91.195.93.3",
"localhost",
"0.0.0.0",
"127.0.0.1"
]

Wyświetl plik

@ -8,13 +8,22 @@ services:
- "8000:8000"
volumes:
- ./:/app
environment:
- SECRET_KEY
- DATABASE_URL
- DJANGO_SETTINGS_MODULE
env_file:
- .env
db:
image: postgres
restart: always
environment:
POSTGRES_ROOT_PASSWORD: password
POSTGRES_USER: comfy
POSTGRES_PASSWORD: password
POSTGRES_DB: comfy_shop
- POSTGRES_ROOT_PASSWORD
- POSTGRES_USER
- POSTGRES_PASSWORD
- POSTGRES_DB
volumes:
- ../postgres/:/var/lib/postgresql
env_file:
- .env

Wyświetl plik

@ -8,13 +8,20 @@ services:
- "8000:8000"
volumes:
- ./:/app
environment:
- SECRET_KEY
- DATABASE_URL
env_file:
- .env
db:
image: postgres
restart: always
environment:
POSTGRES_ROOT_PASSWORD: password
POSTGRES_USER: comfy
POSTGRES_PASSWORD: password
POSTGRES_DB: comfy_shop
- POSTGRES_ROOT_PASSWORD
- POSTGRES_USER
- POSTGRES_PASSWORD
- POSTGRES_DB
volumes:
- ../postgres/:/var/lib/postgresql
env_file:
- .env