# .env.example - Environment variables for Entities API Docker setup # # HOW TO USE: # Option A (recommended): Run the setup script — it auto-generates all secrets # and walks you through optional values interactively: # # entities-api docker-manager --mode up # # Option B (manual): Copy this file to .env and replace every __PLACEHOLDER__ # with a real value before starting the stack. # # cp .env.example .env # # UPDATING OPTIONAL VALUES AFTER SETUP: # entities-api docker-manager configure --set HF_TOKEN=hf_abc123 # entities-api docker-manager configure --interactive # # PLACEHOLDERS KEY: # __GENERATED__ Auto-generated by the setup script. Never set these manually # unless you know what you're doing. Delete .env and re-run # the script to regenerate them safely. # __USER_SUPPLIED__ Must be provided by you. The stack starts without them but # related features will be unavailable until set. # __OPTIONAL__ Leave blank if you are not using this service/feature. ############################# # Base URLs ############################# # All public-facing URLs route through nginx on port 80. ASSISTANTS_BASE_URL=http://localhost:80 SANDBOX_SERVER_URL=http://localhost:80 DOWNLOAD_BASE_URL=http://localhost:80/v1/files/download HYPERBOLIC_BASE_URL=https://api.hyperbolic.xyz/v1 TOGETHER_BASE_URL=https://api.together.xyz/v1 OLLAMA_BASE_URL=http://ollama:11434 ############################# # AI Model Configuration ############################# # Your HuggingFace personal access token. # Required only for downloading gated models via vLLM or the training stack. # Get one at: https://huggingface.co/settings/tokens # The stack starts fine without this — press Enter to skip during setup, # or set it later with: # entities-api docker-manager configure --set HF_TOKEN=hf_abc123 HF_TOKEN=__USER_SUPPLIED__ # Local path where HuggingFace model weights are cached. # Auto-resolved to ~/.cache/huggingface by the setup script if left blank. HF_CACHE_PATH=__USER_SUPPLIED__ # The vLLM model to load on startup (static vllm service, --profile ai). # Override this to switch models, e.g. Qwen/Qwen2.5-VL-7B-Instruct VLLM_MODEL=Qwen/Qwen2.5-VL-3B-Instruct # Extra flags passed to the static vLLM service command. # Leave blank for defaults. Example: --max-model-len 4096 VLLM_EXTRA_FLAGS= ############################# # Database Configuration ############################# # Both DATABASE_URL and SPECIAL_DB_URL are auto-constructed by the setup # script from the individual DB components below. Listed here for reference. DATABASE_URL=mysql+pymysql://api_user:__GENERATED__@db:3306/entities_db SPECIAL_DB_URL=mysql+pymysql://api_user:__GENERATED__@localhost:3307/entities_db # !! Auto-generated by setup script — do not set a weak password manually !! MYSQL_ROOT_PASSWORD=__GENERATED__ MYSQL_DATABASE=entities_db MYSQL_USER=api_user # !! Auto-generated by setup script — do not set a weak password manually !! MYSQL_PASSWORD=__GENERATED__ MYSQL_HOST=db MYSQL_PORT=3306 REDIS_URL=redis://redis:6379/0 ############################# # API Keys & External Services ############################# # !! Auto-generated by setup script !! API_KEY=__GENERATED__ # Third-party inference provider keys — leave blank if not using these providers. TOGETHER_API_KEY=__OPTIONAL__ HYPERBOLIC_API_KEY=__OPTIONAL__ ADMIN_API_KEY=__OPTIONAL__ ENTITIES_API_KEY=__OPTIONAL__ ENTITIES_USER_ID=__OPTIONAL__ DEEP_SEEK_API_KEY=__OPTIONAL__ ############################# # Platform Settings ############################# BASE_URL_HEALTH=http://localhost:80/v1/health SHELL_SERVER_URL=ws://sandbox_api:8000/ws/computer SHELL_SERVER_EXTERNAL_URL=ws://localhost:8000/ws/computer CODE_EXECUTION_URL=ws://sandbox_api:8000/ws/execute # !! Auto-generated by setup script !! SIGNED_URL_SECRET=__GENERATED__ # !! Auto-generated by setup script !! SANDBOX_AUTH_SECRET=__GENERATED__ DISABLE_FIREJAIL=true # !! Auto-generated by setup script !! SECRET_KEY=__GENERATED__ # !! Auto-generated by setup script !! DEFAULT_SECRET_KEY=__GENERATED__ SHARED_PATH=./shared_data AUTO_MIGRATE=1 ############################# # Admin Configuration ############################# ADMIN_USER_EMAIL=admin@example.com ADMIN_USER_ID=__OPTIONAL__ ADMIN_KEY_PREFIX=__OPTIONAL__ ############################# # SMB / Samba Configuration ############################# SMBCLIENT_SERVER=samba_server SMBCLIENT_SHARE=cosmic_share SMBCLIENT_USERNAME=samba_user # !! Auto-generated by setup script !! SMBCLIENT_PASSWORD=__GENERATED__ SMBCLIENT_PORT=445 # Samba process ownership — match your host UID/GID (default 1000) SAMBA_USERID=1000 SAMBA_GROUPID=1000 ############################# # Training Stack (--profile training) ############################# # Training profile controls resource allocation inside the worker. # Options: laptop | standard | high_end # laptop — conservative VRAM usage, smaller batch sizes # standard — balanced defaults for mid-range GPUs # high_end — maximises throughput for 24GB+ VRAM cards TRAINING_PROFILE=laptop # Ray cluster configuration. # RAY_ADDRESS: leave blank to start this node as Ray head. # Set to ray://:10001 to join an existing cluster as a worker. # Adding a new GPU node: set RAY_ADDRESS and run docker compose up training-worker. RAY_ADDRESS= RAY_DASHBOARD_PORT=8265 # Searxng secret key SEARXNG_SECRET_KEY=__GENERATED__ ############################# # Tool Identifiers ############################# # Auto-generated by setup script. Replace only if you need stable IDs # across reinstalls (e.g. if tool IDs are persisted in a database). TOOL_CODE_INTERPRETER=tool___GENERATED__ TOOL_WEB_SEARCH=tool___GENERATED__ TOOL_COMPUTER=tool___GENERATED__ ############################# # Other ############################# LOG_LEVEL=INFO PYTHONUNBUFFERED=1