Merge branch 'main' into feature/mcp-workflow

Added a few settings.
This commit is contained in:
Viswamedha Nalabotu 2025-12-19 00:33:51 +00:00
commit c4d220a294
4 changed files with 31 additions and 0 deletions

View file

@ -37,6 +37,7 @@ RUN pip install --no-cache-dir -r prod.txt
COPY manage.py manage.py COPY manage.py manage.py
COPY config config COPY config config
COPY apps apps COPY apps apps
COPY data data
COPY --from=node /app/build ./build COPY --from=node /app/build ./build

View file

@ -6,5 +6,6 @@ set -o nounset
python manage.py makemigrations python manage.py makemigrations
python manage.py migrate python manage.py migrate
python manage.py loaddata data/site/users.json
python manage.py collectstatic --noinput python manage.py collectstatic --noinput
exec /usr/local/bin/daphne -b 0.0.0.0 -p 8000 config.asgi:application exec /usr/local/bin/daphne -b 0.0.0.0 -p 8000 config.asgi:application

View file

@ -170,5 +170,8 @@ if origins:=os.getenv('DJANGO_CORS_ALLOWED_ORIGINS'):
CORS_ALLOWED_ORIGINS = origins.split(',') CORS_ALLOWED_ORIGINS = origins.split(',')
CORS_ALLOW_CREDENTIALS = True CORS_ALLOW_CREDENTIALS = True
if trusted_origins:=os.getenv('DJANGO_CSRF_TRUSTED_ORIGINS'):
CSRF_TRUSTED_ORIGINS = [origin.strip() for origin in trusted_origins.split(',')]
if DEBUG: if DEBUG:
SECURE_CROSS_ORIGIN_OPENER_POLICY = None SECURE_CROSS_ORIGIN_OPENER_POLICY = None

26
data/site/users.json Normal file
View file

@ -0,0 +1,26 @@
[
{
"model": "users.user",
"pk": 1,
"fields": {
"password": "pbkdf2_sha256$1000000$3z9wkVXkAJggKwrXvhUJJc$swijjGwX6JsYjRvuNECvPxqG8BqMydUjaz1FemMWVL8=",
"last_login": null,
"is_superuser": false,
"created_at": "2025-12-18T23:51:25.301Z",
"updated_at": "2025-12-18T23:51:25.301Z",
"uuid": "5cbef8ca-a24d-4f88-b403-0d53f6a239e6",
"email_address": "a@gmail.com",
"first_name": "a",
"last_name": "a",
"date_of_birth": "2001-01-01",
"bio": "",
"timezone": "UTC",
"avatar_url": "",
"is_active": true,
"is_staff": true,
"role": "employee",
"groups": [],
"user_permissions": []
}
}
]