Merge branch 'main' into main

This commit is contained in:
Yury Kossakovsky
2025-08-21 16:23:43 -06:00
committed by GitHub
10 changed files with 330 additions and 44 deletions

View File

@@ -52,6 +52,7 @@ declare -A VARS_TO_GENERATE=(
# Dify environment variables
["DIFY_SECRET_KEY"]="secret:64" # Dify application secret key (maps to SECRET_KEY in Dify)
["COMFYUI_PASSWORD"]="password:32" # Added ComfyUI basic auth password
["RAGAPP_PASSWORD"]="password:32" # Added RAGApp basic auth password
)
# Initialize existing_env_vars and attempt to read .env if it exists
@@ -409,6 +410,7 @@ generated_values["LANGFUSE_INIT_USER_EMAIL"]="$USER_EMAIL"
generated_values["N8N_WORKER_COUNT"]="$N8N_WORKER_COUNT"
generated_values["WEAVIATE_USERNAME"]="$USER_EMAIL" # Set Weaviate username for Caddy
generated_values["COMFYUI_USERNAME"]="$USER_EMAIL" # Set ComfyUI username for Caddy
generated_values["RAGAPP_USERNAME"]="$USER_EMAIL" # Set RAGApp username for Caddy
if [[ -n "$OPENAI_API_KEY" ]]; then
generated_values["OPENAI_API_KEY"]="$OPENAI_API_KEY"
@@ -438,6 +440,7 @@ found_vars["N8N_WORKER_COUNT"]=0
found_vars["WEAVIATE_USERNAME"]=0
found_vars["NEO4J_AUTH_USERNAME"]=0
found_vars["COMFYUI_USERNAME"]=0
found_vars["RAGAPP_USERNAME"]=0
# Read template, substitute domain, generate initial values
while IFS= read -r line || [[ -n "$line" ]]; do
@@ -484,7 +487,7 @@ while IFS= read -r line || [[ -n "$line" ]]; do
# This 'else' block is for lines from template not covered by existing values or VARS_TO_GENERATE.
# Check if it is one of the user input vars - these are handled by found_vars later if not in template.
is_user_input_var=0 # Reset for each line
user_input_vars=("FLOWISE_USERNAME" "DASHBOARD_USERNAME" "LETSENCRYPT_EMAIL" "RUN_N8N_IMPORT" "PROMETHEUS_USERNAME" "SEARXNG_USERNAME" "OPENAI_API_KEY" "LANGFUSE_INIT_USER_EMAIL" "N8N_WORKER_COUNT" "WEAVIATE_USERNAME" "NEO4J_AUTH_USERNAME" "COMFYUI_USERNAME")
user_input_vars=("FLOWISE_USERNAME" "DASHBOARD_USERNAME" "LETSENCRYPT_EMAIL" "RUN_N8N_IMPORT" "PROMETHEUS_USERNAME" "SEARXNG_USERNAME" "OPENAI_API_KEY" "LANGFUSE_INIT_USER_EMAIL" "N8N_WORKER_COUNT" "WEAVIATE_USERNAME" "NEO4J_AUTH_USERNAME" "COMFYUI_USERNAME" "RAGAPP_USERNAME")
for uivar in "${user_input_vars[@]}"; do
if [[ "$varName" == "$uivar" ]]; then
is_user_input_var=1
@@ -689,6 +692,18 @@ if [[ -z "$FINAL_COMFYUI_HASH" && -n "$COMFYUI_PLAIN_PASS" ]]; then
fi
_update_or_add_env_var "COMFYUI_PASSWORD_HASH" "$FINAL_COMFYUI_HASH"
# --- RAGAPP ---
RAGAPP_PLAIN_PASS="${generated_values["RAGAPP_PASSWORD"]}"
FINAL_RAGAPP_HASH="${generated_values[RAGAPP_PASSWORD_HASH]}"
if [[ -z "$FINAL_RAGAPP_HASH" && -n "$RAGAPP_PLAIN_PASS" ]]; then
NEW_HASH=$(_generate_and_get_hash "$RAGAPP_PLAIN_PASS")
if [[ -n "$NEW_HASH" ]]; then
FINAL_RAGAPP_HASH="$NEW_HASH"
generated_values["RAGAPP_PASSWORD_HASH"]="$NEW_HASH"
fi
fi
_update_or_add_env_var "RAGAPP_PASSWORD_HASH" "$FINAL_RAGAPP_HASH"
if [ $? -eq 0 ]; then # This $? reflects the status of the last mv command from the last _update_or_add_env_var call.
# For now, assuming if we reached here and mv was fine, primary operations were okay.

View File

@@ -55,7 +55,7 @@ base_services_data=(
"flowise" "Flowise (AI Agent Builder)"
"monitoring" "Monitoring Suite (Prometheus, Grafana, cAdvisor, Node-Exporter)"
"portainer" "Portainer (Docker management UI)"
"cloudflare-tunnel" "Cloudflare Tunnel (Zero-Trust Secure Access)"
"cloudflare-tunnel" "Cloudflare Tunnel (Zero-Trust Secure Access)"
"postiz" "Postiz (Social publishing platform)"
"langfuse" "Langfuse Suite (AI Observability - includes Clickhouse, Minio)"
"qdrant" "Qdrant (Vector Database)"
@@ -65,8 +65,10 @@ base_services_data=(
"letta" "Letta (Agent Server & SDK)"
"gotenberg" "Gotenberg (Document Conversion API)"
"crawl4ai" "Crawl4ai (Web Crawler for AI)"
"ragapp" "RAGApp (Open-source RAG UI + API)"
"open-webui" "Open WebUI (ChatGPT-like Interface)"
"searxng" "SearXNG (Private Metasearch Engine)"
"python-runner" "Python Runner (Run your custom Python code from ./python-runner)"
"ollama" "Ollama (Local LLM Runner - select hardware in next step)"
"comfyui" "ComfyUI (Node-based Stable Diffusion UI)"
)
@@ -103,7 +105,7 @@ done
# Use whiptail to display the checklist
CHOICES=$(whiptail --title "Service Selection Wizard" --checklist \
"Choose the services you want to deploy.\nUse ARROW KEYS to navigate, SPACEBAR to select/deselect, ENTER to confirm." 32 90 17 \
"Choose the services you want to deploy.\nUse ARROW KEYS to navigate, SPACEBAR to select/deselect, ENTER to confirm." 32 90 20 \
"${services[@]}" \
3>&1 1>&2 2>&3)

View File

@@ -135,6 +135,26 @@ if is_profile_active "portainer"; then
echo "(Note: On first login, Portainer will prompt to set up an admin user.)"
fi
if is_profile_active "postiz"; then
echo
echo "================================= Postiz =============================="
echo
echo "Host: ${POSTIZ_HOSTNAME:-<hostname_not_set>}"
echo "Internal Access (e.g., from n8n): http://postiz:5000"
fi
if is_profile_active "ragapp"; then
echo
echo "================================= RAGApp =============================="
echo
echo "Host: ${RAGAPP_HOSTNAME:-<hostname_not_set>}"
echo "Internal Access (e.g., from n8n): http://ragapp:8000"
echo "User: ${RAGAPP_USERNAME:-<not_set_in_env>}"
echo "Password: ${RAGAPP_PASSWORD:-<not_set_in_env>}"
echo "Admin: https://${RAGAPP_HOSTNAME:-<hostname_not_set>}/admin"
echo "API Docs: https://${RAGAPP_HOSTNAME:-<hostname_not_set>}/docs"
fi
if is_profile_active "comfyui"; then
echo
echo "================================= ComfyUI ============================="
@@ -175,6 +195,17 @@ if is_profile_active "gotenberg"; then
echo " Office to PDF: POST /forms/libreoffice/convert"
fi
if is_profile_active "python-runner"; then
echo
echo "================================= Python Runner ========================"
echo
echo "Internal Container DNS: python-runner"
echo "Mounted Code Directory: ./python-runner (host) -> /app (container)"
echo "Entry File: /app/main.py"
echo "(Note: Internal-only service with no exposed ports; view output via logs)"
echo "Logs: docker compose -p localai logs -f python-runner"
fi
if is_profile_active "n8n" || is_profile_active "langfuse"; then
echo
echo "================================= Redis (Valkey) ======================"