khoj-aio
Aplicación Docker from JSONbored's Repository
Visión general
Khoj is a self-hosted AI second brain for chatting with your docs, the web, and local or hosted LLMs.
All-In-One Unraid Editionkhoj-aio packages the Khoj server with an internally managed PostgreSQL database so beginners can get a clean first boot on Unraid without wiring a separate database container.
Quick Install (Beginners)
- Install the template and leave the default appdata paths in place.
- Optionally set [code]KHOJ_ADMIN_EMAIL[/code], [code]KHOJ_ADMIN_PASSWORD[/code], and [code]KHOJ_DJANGO_SECRET_KEY[/code].
- Leave [code]KHOJ_ANONYMOUS_MODE=true[/code] for the simplest private LAN-first install, then click Apply.
- Wait for first boot to finish, open [code]http://SERVER_IP:42110[/code], and restart the container once after the initial setup so all settings are applied cleanly.
- If you left the password or secret blank, the container generates secure values and saves them in your mapped config folder at [code]/root/.khoj/aio/generated.env[/code].
Power Users (Advanced View)
- Advanced View exposes the practical upstream self-hosted environment surface plus AIO-specific controls.
- You can keep the bundled internal PostgreSQL default, or point Khoj at external PostgreSQL, search providers, code sandboxes, identity providers, upload storage, Twilio/Notion integrations, and OpenAI-compatible local or hosted LLM endpoints.
- Leave defaults in place for the easiest install. Only set the overrides you actually need.
Important Notes
- This image intentionally keeps PostgreSQL bundled because that is the critical first-boot dependency for Khoj on Unraid. Search, sandbox, and provider integrations remain optional advanced add-ons.
- If you expose Khoj outside your LAN, set strong admin credentials, configure [code]KHOJ_DOMAIN[/code] and [code]KHOJ_ALLOWED_DOMAIN[/code] correctly, and strongly consider disabling anonymous mode.
- Upstream currently documents Google OAuth mainly against the prod [code]khoj-cloud[/code] image, so the Google auth variables below should be treated as expert-only and tested carefully in this standard self-host image flow.
Requisitos
Argumentos en tiempo de ejecución
- Interfaz web
http://[IP]:[PORT:42110]- Red
bridge- Concha
sh- Privilegiado
- false
Configuración de plantillas
The main Khoj web interface port.
- Objetivo
- 42110
- Por defecto
- 42110
- Valor
- 42110
Stores generated credentials, uploads, and Khoj configuration state.
- Objetivo
- /root/.khoj
- Por defecto
- /mnt/user/appdata/khoj-aio/config
- Valor
- /mnt/user/appdata/khoj-aio/config
Internal PostgreSQL database storage for the AIO deployment.
- Objetivo
- /var/lib/postgresql/data
- Por defecto
- /mnt/user/appdata/khoj-aio/postgres
- Valor
- /mnt/user/appdata/khoj-aio/postgres
Admin login email for the Khoj admin panel. You can change it later.
- Objetivo
- KHOJ_ADMIN_EMAIL
- Por defecto
- admin@khoj.local
- Valor
- admin@khoj.local
Optional. Leave blank to auto-generate a secure admin password on first boot and save it in the mapped config folder.
- Objetivo
- KHOJ_ADMIN_PASSWORD
Optional but recommended. Leave blank to auto-generate a secure secret key on first boot and save it in the mapped config folder.
- Objetivo
- KHOJ_DJANGO_SECRET_KEY
Leave true for the simplest single-user LAN-first install. Set false if you want user sign-in and multi-user auth flows.
- Objetivo
- KHOJ_ANONYMOUS_MODE
- Por defecto
- true|false
- Valor
- true
Persistent cache for Hugging Face downloads and model assets.
- Objetivo
- /root/.cache/huggingface
- Por defecto
- /mnt/user/appdata/khoj-aio/models/huggingface
- Valor
- /mnt/user/appdata/khoj-aio/models/huggingface
Persistent cache for SentenceTransformers embeddings and related model files.
- Objetivo
- /root/.cache/torch/sentence_transformers
- Por defecto
- /mnt/user/appdata/khoj-aio/models/sentence-transformers
- Valor
- /mnt/user/appdata/khoj-aio/models/sentence-transformers
Optional Docker socket mount for advanced operator/computer workflows. Do not enable this unless you understand the security tradeoff.
- Objetivo
- /var/run/docker.sock
Default single-container mode. Set false only if you are intentionally using an external PostgreSQL database.
- Objetivo
- KHOJ_USE_INTERNAL_POSTGRES
- Por defecto
- true|false
- Valor
- true
Container bind address. Leave at 0.0.0.0 for standard Unraid bridge networking.
- Objetivo
- KHOJ_HOST
- Por defecto
- 0.0.0.0
- Valor
- 0.0.0.0
Recommended for unattended container startup.
- Objetivo
- KHOJ_NON_INTERACTIVE
- Por defecto
- true|false
- Valor
- true
Optional extra arguments appended to the Khoj startup command.
- Objetivo
- KHOJ_EXTRA_ARGS
Set true only when troubleshooting with more verbose upstream debug behavior.
- Objetivo
- KHOJ_DEBUG
- Por defecto
- false|true
- Valor
- false
Optional worker-process override. Leave blank for the upstream default.
- Objetivo
- GUNICORN_WORKERS
Optional request timeout in seconds. Leave blank for the upstream default.
- Objetivo
- GUNICORN_TIMEOUT
Optional graceful shutdown timeout in seconds. Leave blank for the upstream default.
- Objetivo
- GUNICORN_GRACEFUL_TIMEOUT
Optional keep-alive timeout in seconds. Leave blank for the upstream default.
- Objetivo
- GUNICORN_KEEP_ALIVE
Optional deterministic seed for supported model providers. Useful for repeatable debugging and testing.
- Objetivo
- KHOJ_LLM_SEED
Optional cap for research-mode iterations. Leave blank for the upstream default.
- Objetivo
- KHOJ_RESEARCH_ITERATIONS
Optional external PostgreSQL host. When set, the bundled PostgreSQL stays idle.
- Objetivo
- POSTGRES_HOST
External PostgreSQL port.
- Objetivo
- POSTGRES_PORT
- Por defecto
- 5432
- Valor
- 5432
External PostgreSQL database name.
- Objetivo
- POSTGRES_DB
- Por defecto
- postgres
- Valor
- postgres
External PostgreSQL username.
- Objetivo
- POSTGRES_USER
- Por defecto
- postgres
- Valor
- postgres
External PostgreSQL password.
- Objetivo
- POSTGRES_PASSWORD
API key for OpenAI itself or other OpenAI-compatible gateways that require auth.
- Objetivo
- OPENAI_API_KEY
Anthropic API key for Claude models. Also required for Khoj operator/computer workflows.
- Objetivo
- ANTHROPIC_API_KEY
Google Gemini API key for Gemini chat or image workflows.
- Objetivo
- GEMINI_API_KEY
Use this for Ollama, vLLM, LM Studio, LiteLLM, LocalAI, or any OpenAI-compatible endpoint. Example: http://host.docker.internal:11434/v1/.
- Objetivo
- OPENAI_BASE_URL
Optional default chat model name for your configured OpenAI-compatible endpoint.
- Objetivo
- KHOJ_DEFAULT_CHAT_MODEL
Optional SearxNG endpoint for online search. Example: http://192.168.1.20:8080.
- Objetivo
- KHOJ_SEARXNG_URL
Optional paid web-search API key from Serper.
- Objetivo
- SERPER_DEV_API_KEY
Optional Google Custom Search JSON API key for expert search routing.
- Objetivo
- GOOGLE_SEARCH_API_KEY
Optional Google Programmable Search Engine ID paired with GOOGLE_SEARCH_API_KEY.
- Objetivo
- GOOGLE_SEARCH_ENGINE_ID
Optional webpage-read API key from OloStep.
- Objetivo
- OLOSTEP_API_KEY
Optional OloStep API base URL override. Leave blank for the upstream default.
- Objetivo
- OLOSTEP_API_URL
Optional Firecrawl API key for search and webpage reading.
- Objetivo
- FIRECRAWL_API_KEY
Optional Firecrawl API base URL override. Leave blank for the upstream default.
- Objetivo
- FIRECRAWL_API_URL
Optional Exa API key for search and webpage reading.
- Objetivo
- EXA_API_KEY
Optional Exa API base URL override. Leave blank for the upstream default.
- Objetivo
- EXA_API_URL
Set true to have Khoj automatically read a small number of search result pages while researching online.
- Objetivo
- KHOJ_AUTO_READ_WEBPAGE
- Por defecto
- false|true
- Valor
- false
Optional external Terrarium sandbox URL for code execution. Example: http://192.168.1.30:8080.
- Objetivo
- KHOJ_TERRARIUM_URL
Optional E2B API key if you want remote code sandboxing instead of Terrarium.
- Objetivo
- E2B_API_KEY
Optional E2B template override. Leave blank for Khoj's upstream default template.
- Objetivo
- E2B_TEMPLATE
Set true only if you intentionally enable Khoj's operator/computer features and understand the extra security and resource cost.
- Objetivo
- KHOJ_OPERATOR_ENABLED
- Por defecto
- false|true
- Valor
- false
Optional max-iteration cap for operator runs. Leave blank for the upstream default.
- Objetivo
- KHOJ_OPERATOR_ITERATIONS
Optional Chrome DevTools Protocol URL for expert external-browser operator setups.
- Objetivo
- KHOJ_CDP_URL
Required for remote access through a custom hostname or IP. Do not include http:// or https://.
- Objetivo
- KHOJ_DOMAIN
Optional internal hostname/IP for reverse proxy or load balancer setups. If blank, Khoj defaults to KHOJ_DOMAIN.
- Objetivo
- KHOJ_ALLOWED_DOMAIN
Set true when intentionally serving over plain HTTP on a trusted LAN or behind a reverse proxy that terminates TLS.
- Objetivo
- KHOJ_NO_HTTPS
- Por defecto
- true|false
- Valor
- true
Optional. Enables emailed magic-link login for multi-user access.
- Objetivo
- RESEND_API_KEY
Optional sender address used for magic-link authentication emails.
- Objetivo
- RESEND_EMAIL
Optional Resend audience ID if you want Khoj to add users to a Resend audience after welcome email flows.
- Objetivo
- RESEND_AUDIENCE_ID
Expert-only Google OAuth client ID. Upstream currently documents Google auth mainly against the prod khoj-cloud image.
- Objetivo
- GOOGLE_CLIENT_ID
Expert-only Google OAuth client secret paired with GOOGLE_CLIENT_ID.
- Objetivo
- GOOGLE_CLIENT_SECRET
Optional. Enables text-to-speech voice responses using ElevenLabs.
- Objetivo
- ELEVEN_LABS_API_KEY
Optional Notion OAuth client ID for advanced self-hosted Notion integration flows.
- Objetivo
- NOTION_OAUTH_CLIENT_ID
Optional Notion OAuth client secret.
- Objetivo
- NOTION_OAUTH_CLIENT_SECRET
Optional Notion OAuth redirect URI registered with your integration.
- Objetivo
- NOTION_REDIRECT_URI
Optional object-storage access key for advanced image upload offload paths.
- Objetivo
- AWS_ACCESS_KEY
Optional object-storage secret key paired with AWS_ACCESS_KEY.
- Objetivo
- AWS_SECRET_KEY
Optional bucket name for Khoj-generated image uploads.
- Objetivo
- AWS_IMAGE_UPLOAD_BUCKET
Optional bucket name for user-uploaded images.
- Objetivo
- AWS_USER_UPLOADED_IMAGES_BUCKET_NAME
Optional Twilio Account SID for Twilio-backed verification or messaging flows.
- Objetivo
- TWILIO_ACCOUNT_SID
Optional Twilio auth token paired with TWILIO_ACCOUNT_SID.
- Objetivo
- TWILIO_AUTH_TOKEN
Optional Twilio Verify service SID.
- Objetivo
- TWILIO_VERIFICATION_SID
Set true to opt out of Khoj's anonymous self-hosted telemetry.
- Objetivo
- KHOJ_TELEMETRY_DISABLE
- Por defecto
- false|true
- Valor
- false
Categorías
Descargar estadísticas
Detalles
jsonbored/khoj-aio:latestEjecute khoj-aio en Unraid.
khoj-aio se encuentra en Community Apps para Unraid OS. Explore Unraid para crear un servidor doméstico flexible, un NAS o un laboratorio doméstico.