Files
monica_site/.env.example
T
westfarn bc7c47a69c
Deploy Beta / unit-tests (push) Successful in 21s
Deploy Beta / docker (push) Successful in 24s
Deploy Beta / deploy-beta (push) Successful in 2m4s
Mint short links on piha.lc / beta.piha.li (#12)
## Summary
- Point `SHORTENER_BASE_URL` at `https://piha.lc` (prod) and `https://beta.piha.li` (beta).
- Stop documenting `shortener.aimloperations.com` as the mint host.

Closes #11.

Depends on url_shortening_service serving `/api/` on the short host.

## Test plan
- [ ] Set `SHORTENER_BASE_URL=https://beta.piha.li` and matching token in beta env
- [ ] Compose a campaign SMS and confirm mint hits beta.piha.li (not shortener-beta)
- [ ] Body contains `https://beta.piha.li/<code>`

Reviewed-on: #12
2026-08-30 17:27:51 -07:00

107 lines
4.1 KiB
Bash

# Local development defaults. Copy to `.env` (gitignored) — never commit secrets.
# docker compose auto-loads `.env` for ${VAR} substitution into the web container.
DJANGO_ENV=dev
DJANGO_DEBUG=true
DJANGO_SECRET_KEY=dev-only-change-me
DJANGO_ALLOWED_HOSTS=localhost,127.0.0.1,0.0.0.0
# Leave empty for SQLite, or point at local compose Postgres:
# DATABASE_URL=postgres://monica_site:monica_site@127.0.0.1:5432/monica_site
SITE_UNDER_CONSTRUCTION=false
SITE_NAME=Monica Dhillon
SITE_TAGLINE=MKDRealtor.com · EXIT Realty
PUBLIC_SITE_URL=http://127.0.0.1:8000
CONTACT_PHONE=(630) 452-4443
CONTACT_EMAIL=moni.dhill@gmail.com
CONTACT_ADDRESS=1245 Butterfield Rd. #100, Wheaton, IL 60189
CONTACT_SERVICE_AREA=Serving Chicago's western suburbs
CREDIT_NAME=AI ML Operations, LLC
CREDIT_URL=https://aimloperations.com
# reCAPTCHA (optional locally — form skips captcha when empty)
RECAPTCHA_PUBLIC_KEY=
RECAPTCHA_PRIVATE_KEY=
# SMTP2GO — fill in `.env` (not this file). Dev defaults to console backend
# until you set EMAIL_BACKEND to the SMTP backend below.
EMAIL_HOST=mail.smtp2go.com
# SMTP login (not shown to recipients)
EMAIL_HOST_USER=
EMAIL_HOST_PASSWORD=
EMAIL_PORT=2525
EMAIL_USE_TLS=true
# Inbox From header. Docker Compose .env cannot parse: "Name" <addr>
# (the <addr> breaks the parser). Use ONE of:
# DEFAULT_FROM_EMAIL=notifications-beta@mkdrealtor.com
# → app wraps with SITE_NAME → "Monica Dhillon" <notifications-beta@…>
# DEFAULT_FROM_EMAIL="Monica Dhillon <notifications-beta@mkdrealtor.com>"
# → whole value in one pair of quotes (compose-safe)
DEFAULT_FROM_EMAIL=noreply@mkdrealtor.com
# Console (default in DJANGO_ENV=dev) prints mail to container logs.
# For real SMTP2GO delivery locally, uncomment:
# EMAIL_BACKEND=django.core.mail.backends.smtp.EmailBackend
SMTP2GO_SMS_API_KEY=
# Shared secret for the unified SMTP2GO webhook (email + SMS).
# In SMTP2GO: one webhook URL …/webhooks/smtp2go/ ; Authorization = Bearer + this secret.
SMTP2GO_WEBHOOK_SECRET=
# Postcards — PCM Integrations (DirectMail API v3)
# Portal → My Account → API Keys: copy Sandbox or Production key + secret.
# App POSTs /auth/login then uses the returned Bearer token (not the raw key).
POSTCARD_PROVIDER=pcm
PCM_API_KEY=
PCM_API_SECRET=
# Optional: PCM_CHILD_REF_NBR=
# Inbound webhook auth — PCM generates one signature secret per subscription.
# Paste all of them comma-separated (also accepts single PCM_WEBHOOK_SECRET=).
PCM_WEBHOOK_SECRETS=
# PCM_WEBHOOK_SECRET=
# Required return address on every postcard order.
# Quote the JSON (compose/shell break on bare {…, …}).
# PCM_RETURN_ADDRESS='{"firstName":"Monica","lastName":"Dhillon","address":"1245 Butterfield Rd.","address2":"#100","city":"Wheaton","state":"IL","zipCode":"60189"}'
PCM_RETURN_ADDRESS=
# Or set fields individually if JSON is empty:
# PCM_RETURN_LINE1=
# PCM_RETURN_CITY=
# PCM_RETURN_STATE=
# PCM_RETURN_ZIP=
# Social
# LinkedIn / Instagram App ID + Secret: Portal → Social accounts (not env).
META_APP_ID=
META_APP_SECRET=
# Generate: python -c "from cryptography.fernet import Fernet; print(Fernet.generate_key().decode())"
SOCIAL_TOKEN_ENCRYPTION_KEY=
# Ollama (LAN) — standard Ollama HTTP port
OLLAMA_BASE_URL=http://10.0.0.128:11434
OLLAMA_MODEL=llama3.2
# URL shortener (piha.lc). Empty locally = long UTM URLs in campaigns.
# Call the short host: POST /api/links/ (Bearer) and recipients GET /<code>.
SHORTENER_BASE_URL=
SHORTENER_API_TOKEN=
# Local shortener compose:
# SHORTENER_BASE_URL=http://127.0.0.1:8005
# SHORTENER_API_TOKEN=monica:dev-only-token
# Nominatim (LAN) — address autocomplete via Django /api/address-suggest/
# Nominatim has no built-in API keys; optional NOMINATIM_API_KEY only if you
# put a gateway in front that checks X-API-Key.
NOMINATIM_BASE_URL=http://10.0.0.128:8089
NOMINATIM_TIMEOUT_SECONDS=8
NOMINATIM_COUNTRY_CODES=us
# NOMINATIM_API_KEY=
# Tianji analytics (off in local/dev by default)
TIANJI_ENABLED=false
TIANJI_TRACKER_URL=https://tianji.aimloperations.com/tracker.js
TIANJI_WEBSITE_ID=cmshzhxdf6gee10qzkzrfn9iw
# Worker poll interval for due scheduled campaigns / social posts (seconds).
# DISPATCH_DUE_INTERVAL_SECONDS=15
GUNICORN_WORKERS=2