mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-12-15 21:33:05 +00:00
feat(bookwyrm): production-ready runtime + Redis wiring
- Dockerfile: build & install gunicorn wheels - compose: run initdb before start; use `python -m gunicorn` - env: add POSTGRES_* and BookWyrm Redis aliases (BROKER/ACTIVITY/CACHE) + CACHE_URL - vars: add cache URL, DB indices, and URL aliases for Redis Ref: https://chatgpt.com/share/68b7492b-3200-800f-80c4-295bc3233d68
This commit is contained in:
@@ -22,17 +22,39 @@ EMAIL_HOST_PASSWORD="{{ EMAIL_HOST_PASSWORD }}"
|
||||
DEFAULT_FROM_EMAIL="{{ EMAIL_DEFAULT_FROM }}"
|
||||
|
||||
# Database
|
||||
POSTGRES_DB="{{ database_name }}"
|
||||
POSTGRES_USER="{{ database_username }}"
|
||||
POSTGRES_PASSWORD="{{ database_password }}"
|
||||
POSTGRES_HOST="{{ database_host }}"
|
||||
POSTGRES_PORT="{{ database_port }}"
|
||||
DATABASE_URL="postgres://{{ database_username }}:{{ database_password }}@{{ database_host }}:{{ database_port }}/{{ database_name }}"
|
||||
|
||||
# Redis / Celery
|
||||
REDIS_HOST="{{ BOOKWYRM_REDIS_HOST }}"
|
||||
REDIS_PORT="{{ BOOKWYRM_REDIS_PORT }}"
|
||||
REDIS_URL="{{ BOOKWYRM_REDIS_CACHE_URL }}"
|
||||
REDIS_CACHE_URL="{{ BOOKWYRM_REDIS_CACHE_URL }}"
|
||||
CACHE_URL="{{ BOOKWYRM_REDIS_CACHE_URL }}"
|
||||
DJANGO_REDIS_URL="{{ BOOKWYRM_REDIS_CACHE_URL }}"
|
||||
|
||||
## Broker
|
||||
BROKER_URL="{{ BOOKWYRM_BROKER_URL }}"
|
||||
REDIS_BROKER_URL="{{ BOOKWYRM_REDIS_BROKER_URL }}"
|
||||
REDIS_CACHE_URL="{{ BOOKWYRM_REDIS_BASE_URL }}/1"
|
||||
REDIS_BROKER_HOST="{{ BOOKWYRM_REDIS_HOST }}"
|
||||
REDIS_BROKER_PORT="{{ BOOKWYRM_REDIS_PORT }}"
|
||||
REDIS_BROKER_DB_INDEX="{{ BOOKWYRM_REDIS_BROKER_DB }}"
|
||||
CELERY_BROKER_URL="{{ BOOKWYRM_REDIS_BROKER_URL }}"
|
||||
|
||||
## Activity
|
||||
REDIS_ACTIVITY_HOST="{{ BOOKWYRM_REDIS_HOST }}"
|
||||
REDIS_ACTIVITY_PORT="{{ BOOKWYRM_REDIS_PORT }}"
|
||||
REDIS_ACTIVITY_DB_INDEX="{{ BOOKWYRM_REDIS_ACTIVITY_DB }}"
|
||||
REDIS_ACTIVITY_URL="{{ BOOKWYRM_REDIS_ACTIVITY_URL }}"
|
||||
|
||||
# Proxy (if BookWyrm sits behind reverse proxy)
|
||||
FORWARDED_ALLOW_IPS="*"
|
||||
USE_X_FORWARDED_HOST="true"
|
||||
SECURE_PROXY_SSL_HEADER="HTTP_X_FORWARDED_PROTO,{{ WEB_PROTOCOL }}"
|
||||
SECURE_PROXY_SSL_HEADER="{{ (WEB_PORT == 443) | string | lower }}"
|
||||
|
||||
# OIDC (optional – only if BOOKWYRM_OIDC_ENABLED)
|
||||
{% if BOOKWYRM_OIDC_ENABLED %}
|
||||
|
||||
Reference in New Issue
Block a user