A setting to turn off the models.dev catalog download (offline and strict-network use)
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 72/100
Línea de trabajo
Empieza en pkg/modelsdev/store.go: lee fetchFromAPI, loadDatabase y getDatabase para ver cómo la flag allowFetch ya controla la ruta de red y cómo funcionan la caché y el snapshot embebido como fallbacks. La propuesta es añadir una variable de entorno (por ejemplo, DOCKER_AGENT_OFFLINE o DOCKER_AGENT_MODELS_DEV=off) que haga que getDatabase se comporte como allowFetch=false. Comprueba cómo se parsean y documentan switches existentes como TELEMETRY_ENABLED, haz lo mismo y añade un test que verifique que el catálogo se sirve desde caché/snapshot sin ninguna llamada de red. Hecho: la configuración impide cualquier fetch de https://models.dev/api.json y los tests existentes siguen pasando.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What happens
On v1.152.0, docker-agent run downloads the public model catalog from https://models.dev/api.json. That's pkg/modelsdev/store.go, fetchFromAPI. It caches the catalog for 24 hours in $XDG_CACHE_HOME/cagent/models_dev.json. When a deployment gives each session its own HOME, which is common when docker-agent runs as a sandboxed agent runtime, that means one download per new session per day.
The other outbound paths each have a switch:
TELEMETRY_ENABLED=falsefor telemetry;DOCKER_AGENT_AUTO_UPDATEfor self-update;DOCKER_AGENT_AUTO_INSTALL=falsefor tool install;--otelis opt-in.
The catalog download is the one an operator can't turn off.
Why a switch would be enough
The store already handles a failed or blocked download. loadDatabase falls back to the cache, and then to the snapshot embedded at build time (the behaviour #3165 made explicit). So a setting that skips the download and goes straight to cache-or-embedded would only formalise a path that already works.
That matters for deployments that must not make outbound calls beyond the model provider they configured: air-gapped installs, strict egress policies, or self-hosters who want only the calls they asked for.
Proposal
Something like DOCKER_AGENT_OFFLINE=1, or a narrower DOCKER_AGENT_MODELS_DEV=off. It would make getDatabase behave as allowFetch=false: cache if present, otherwise the embedded snapshot, and never the network.
We run docker-agent as one of the agent runtimes in the open-source HarnessRouter. For now, our docs tell self-hosters that it fetches from models.dev and that the host can be blocked. A switch would let us turn it off by default. Thanks for considering it.
- Lenguaje dominante
- Go
- Estrellas
- 4.6k
- Forks
- 529
- Merge medio
- 14 h 22 min
- PR fusionados (30 d)
- 181
Preparar el entorno
Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin plantilla de pull request
- Sin guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de docker/docker-agent
-
Error when trying to run sandbox example?Posiblemente ocupada @dgageot la tomó hace 7 días. Abiertoarea/cli
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
docker/docker-agent#4672 · 1 comentario · 1 reacción · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
pkg/hooks tests fail with a misleading assertion when jq is not installedPosiblemente ocupada @dwin-gharibi la tomó hace 65 días. Abiertoarea/testing
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
docker/docker-agent#4052 ·
Los mantenedores suelen responder en 1 día
-
`remove_directory` and `create_directory` hide work they already did when a later path failsPosiblemente ocupada @dwin-gharibi la tomó hace 83 días. Abiertoarea/tools
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
docker/docker-agent#3933 ·
Los mantenedores suelen responder en 1 día
-
`edit_file` silently edits the first match when `oldText` occurs more than oncePosiblemente ocupada @dwin-gharibi la tomó hace 83 días. Abiertoarea/tools
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
docker/docker-agent#3929 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Allow enabling the streamable-HTTP standalone SSE stream from YAML for remote MCP toolsetsPosiblemente ocupada @steilerDev la tomó hace 1 día. Abiertoarea/config area/mcp area/tools
Dificultad 3/5 1-2 días Aptitud para principiantes 72/100
docker/docker-agent#4722 ·
Los mantenedores suelen responder en 1 día
Todos los issues de docker/docker-agent
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
-
Energy flow: add an "Other" row so the consumers add up to the consumption totalPosiblemente ocupada @github-actions la tomó hoy. Abiertoenhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 73/100
evcc-io/evcc#35512 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
nebari-dev/nebi#630 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
router-for-me/CLIProxyAPI#7084 ·
Los mantenedores suelen responder en 1 día