trypost/docker/.env.docker.example
Hafiz Muhammad Moaz 06fd0ba53d
docs: surface per-provider AI model override env vars (#290)
* docs: surface per-provider AI model override env vars

.env.example only showed AI_TEXT_PROVIDER/AI_IMAGE_PROVIDER/
AI_AUDIO_PROVIDER (which provider to use), never the per-provider
model overrides (OPENAI_IMAGE_MODEL, GEMINI_AUDIO_MODEL, etc.) that
config/ai.php already wires up for every provider capability. A
self-hoster reading only .env.example had no way to discover these
existed.

These aren't new: laravel/ai already resolves each capability's
model independently per provider (confirmed in vendor - e.g.
OpenAiProvider::defaultImageModel() falls back to a hardcoded image
model, never to the text model), so there was never actually a
text-model fallback bug to fix in code. The gap was purely that the
override knobs were invisible outside of reading config/ai.php's
source directly.

* docs: document AI provider keys, URLs and example model values

The override block landed with bare variable names and only covered the
five providers whose API keys were already in .env.example. Filled in
what a self-hoster still could not discover:

- Example values on every model override, taken from laravel/ai's
  current per-capability defaults, so the ID format is visible (an
  Ollama tag, an OpenRouter vendor/model path and a bare OpenAI ID
  look nothing alike).
- The keys and URLs for the providers .env.example already advertises
  as valid but never documented: XAI, GROQ, MISTRAL, DEEPSEEK,
  OLLAMA_URL and the openai-compatible endpoint. Ollama was the
  scenario in the original report and OLLAMA_URL matters more there
  than OLLAMA_TEXT_MODEL does.
- GROQ/MISTRAL/DEEPSEEK text models, missing while their providers
  were listed as options.
- openai-compatible has no built-in default model and throws without
  OPENAI_COMPATIBLE_TEXT_MODEL, so that one is flagged as required.
- Corrected the audio provider list: gemini and openrouter implement
  AudioProvider too. The image and audio lists are no longer written
  as exhaustive.
- Mirrored all of it into docker/.env.docker.example, which carried the
  same block untouched and is the file Docker self-hosters copy. Its
  OLLAMA_URL points at the host instead of localhost.

---------

Co-authored-by: Paulo Castellano <paulo@castellanos.llc>
2026-08-26 11:13:06 -03:00

222 lines
6.6 KiB
Text

APP_NAME="TryPost"
APP_ENV=local
APP_KEY=
APP_DEBUG=true
APP_URL=http://localhost:8000
# Public base URL inbound webhooks (e.g. Telegram) are registered on.
# Defaults to APP_URL; set a tunnel URL (e.g. ngrok) for local development.
WEBHOOK_URL=
# Self-hosted mode (skips payment requirements)
SELF_HOSTED=true
# Allow more than one connected account per social network in a workspace.
ALLOW_MULTIPLE_SOCIAL_ACCOUNTS=true
TELESCOPE_ENABLED=false
APP_LOCALE=en
APP_FALLBACK_LOCALE=en
APP_FAKER_LOCALE=en_US
APP_MAINTENANCE_DRIVER=file
BCRYPT_ROUNDS=12
LOG_CHANNEL=stack
LOG_STACK=single
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug
# Database — service name "pgsql" inside the Compose network.
DB_CONNECTION=pgsql
DB_HOST=pgsql
DB_PORT=5432
DB_DATABASE=trypost
DB_USERNAME=postgres
DB_PASSWORD=password
# Session
SESSION_DRIVER=database
SESSION_LIFETIME=1440
SESSION_ENCRYPT=false
SESSION_PATH=/
SESSION_DOMAIN=null
# Broadcasting, Queue, Cache — all Redis-backed in Docker.
BROADCAST_CONNECTION=reverb
QUEUE_CONNECTION=redis
CACHE_STORE=redis
# File Storage — local-disk by default; switch to s3/r2 for production.
FILESYSTEM_DISK=local
# Redis — service name "redis" inside the Compose network.
REDIS_HOST=redis
REDIS_PASSWORD=null
REDIS_PORT=6379
# Mail — service name "mailpit" inside the Compose network. UI at :8025.
MAIL_MAILER=smtp
MAIL_HOST=mailpit
MAIL_PORT=1025
MAIL_USERNAME=null
MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS="hello@example.com"
MAIL_FROM_NAME="${APP_NAME}"
# Reverb (WebSockets) — host=localhost is browser-perspective via host port-forward.
REVERB_APP_ID=1001
REVERB_APP_KEY=trypost-reverb-key
REVERB_APP_SECRET=trypost-reverb-secret
REVERB_HOST=localhost
REVERB_PORT=8080
REVERB_SCHEME=http
# AWS S3 (set FILESYSTEM_DISK=s3)
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=us-east-1
AWS_BUCKET=
AWS_URL=
# Cloudflare R2 (set FILESYSTEM_DISK=r2)
R2_ACCESS_KEY_ID=
R2_SECRET_ACCESS_KEY=
R2_ENDPOINT=
R2_REGION=auto
R2_BUCKET=
R2_URL=
# ============================================
# Social Platform Credentials (optional in dev)
# ============================================
LINKEDIN_CLIENT_ID=
LINKEDIN_CLIENT_SECRET=
LINKEDIN_CLIENT_REDIRECT="${APP_URL}/accounts/linkedin/callback"
# LINKEDIN_SCOPES="openid,profile,email,w_member_social"
LINKEDIN_PAGE_CLIENT_REDIRECT="${APP_URL}/accounts/linkedin-page/callback"
# LINKEDIN_PAGE_SCOPES="openid,profile,email,w_organization_social,r_organization_social,rw_organization_admin,w_member_social"
X_CLIENT_ID=
X_CLIENT_SECRET=
X_CLIENT_REDIRECT="${APP_URL}/accounts/x/callback"
TIKTOK_CLIENT_ID=
TIKTOK_CLIENT_SECRET=
TIKTOK_CLIENT_REDIRECT="${APP_URL}/accounts/tiktok/callback"
FACEBOOK_CLIENT_ID=
FACEBOOK_CLIENT_SECRET=
FACEBOOK_CLIENT_REDIRECT="${APP_URL}/accounts/facebook/callback"
INSTAGRAM_CLIENT_ID=
INSTAGRAM_CLIENT_SECRET=
INSTAGRAM_CLIENT_REDIRECT="${APP_URL}/accounts/instagram/callback"
THREADS_CLIENT_ID=
THREADS_CLIENT_SECRET=
THREADS_CLIENT_REDIRECT="${APP_URL}/accounts/threads/callback"
GOOGLE_AUTH_ENABLED=false
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
GOOGLE_CLIENT_REDIRECT="${APP_URL}/accounts/youtube/callback"
GOOGLE_AUTH_CALLBACK="${APP_URL}/auth/google/callback"
GITHUB_AUTH_ENABLED=false
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
GITHUB_AUTH_CALLBACK="${APP_URL}/auth/github/callback"
PINTEREST_CLIENT_ID=
PINTEREST_CLIENT_SECRET=
PINTEREST_CLIENT_REDIRECT="${APP_URL}/accounts/pinterest/callback"
# Telegram (single shared bot — create one via https://t.me/BotFather)
# After setting these, run: php artisan telegram:set-webhook
TELEGRAM_BOT_TOKEN=
TELEGRAM_BOT_USERNAME=
TELEGRAM_WEBHOOK_SECRET=
# AI Services
OPENAI_API_KEY=
ANTHROPIC_API_KEY=
GEMINI_API_KEY=
OPENROUTER_API_KEY=
ELEVENLABS_API_KEY=
# Only needed if you point one of the AI_*_PROVIDER vars below at these providers.
# XAI_API_KEY=
# GROQ_API_KEY=
# MISTRAL_API_KEY=
# DEEPSEEK_API_KEY=
# Ollama runs locally and needs no key — from inside Docker point it at the host, not localhost.
# OLLAMA_URL=http://host.docker.internal:11434
# Any OpenAI-compatible endpoint (LM Studio, vLLM, LocalAI, ...) via AI_TEXT_PROVIDER=openai-compatible.
# It has no built-in default model, so OPENAI_COMPATIBLE_TEXT_MODEL is required for that provider.
# OPENAI_COMPATIBLE_URL=
# OPENAI_COMPATIBLE_API_KEY=
# OPENAI_COMPATIBLE_TEXT_MODEL=
# AI Provider Selection
# text: openai | anthropic | gemini | openrouter | xai | groq | mistral | deepseek | ollama | ...
# image: openai | gemini | xai | openrouter | ...
# audio: openai | elevenlabs | gemini | openrouter | ...
# OpenRouter is a first-class laravel/ai provider (AI_TEXT_PROVIDER=openrouter + OPENROUTER_API_KEY).
AI_TEXT_PROVIDER=openai
AI_IMAGE_PROVIDER=openai
AI_AUDIO_PROVIDER=elevenlabs
# AI Model Overrides (optional)
# Each provider picks a sensible default model per capability on its own -
# these are NOT shared across capabilities, so overriding one (e.g. a text
# model) never affects another (e.g. that same provider's image model).
# Uncomment only the ones you want to override; every provider in play above
# (AI_TEXT_PROVIDER / AI_IMAGE_PROVIDER / AI_AUDIO_PROVIDER) reads its own set.
# The values below are laravel/ai's current defaults, shown as format examples -
# they move with the package, so don't treat them as a contract.
# OPENAI_TEXT_MODEL=gpt-5.4
# OPENAI_IMAGE_MODEL=gpt-image-2
# OPENAI_AUDIO_MODEL=gpt-4o-mini-tts
# ANTHROPIC_TEXT_MODEL=claude-sonnet-5
# GEMINI_TEXT_MODEL=gemini-3.6-flash
# GEMINI_IMAGE_MODEL=gemini-3.1-flash-image-preview
# GEMINI_AUDIO_MODEL=gemini-2.5-flash-preview-tts
# XAI_TEXT_MODEL=grok-4.20-non-reasoning
# XAI_IMAGE_MODEL=grok-imagine-image
# OPENROUTER_TEXT_MODEL=anthropic/claude-sonnet-4.6
# OPENROUTER_IMAGE_MODEL=google/gemini-3.1-flash-image-preview
# OPENROUTER_AUDIO_MODEL=google/gemini-3.1-flash-tts-preview
# ELEVENLABS_AUDIO_MODEL=eleven_multilingual_v2
# GROQ_TEXT_MODEL=openai/gpt-oss-120b
# MISTRAL_TEXT_MODEL=mistral-medium-latest
# DEEPSEEK_TEXT_MODEL=deepseek-v4-flash
# OLLAMA_TEXT_MODEL=llama3.1:8b
# Ollama has no image/audio-capable driver in laravel/ai - text only.
# Telemetry — disabled by default in Docker dev.
NIGHTWATCH_ENABLED=false
NIGHTWATCH_TOKEN=
# Media Services
UNSPLASH_ACCESS_KEY=
UNSPLASH_SECRET_KEY=
GIPHY_API_KEY=
# Analytics (optional)
GTM_ID=
POSTHOG_ENABLED=false
POSTHOG_API_KEY=
POSTHOG_HOST=https://us.i.posthog.com
# Vite
VITE_APP_NAME="${APP_NAME}"
VITE_REVERB_APP_KEY="${REVERB_APP_KEY}"
VITE_REVERB_HOST="${REVERB_HOST}"
VITE_REVERB_PORT="${REVERB_PORT}"
VITE_REVERB_SCHEME="${REVERB_SCHEME}"
VITE_POSTHOG_ENABLED="${POSTHOG_ENABLED}"
VITE_POSTHOG_API_KEY="${POSTHOG_API_KEY}"
VITE_POSTHOG_HOST="${POSTHOG_HOST}"