SShortSingh.
Back to feed

Developer builds local AI agent to diagnose Docker containers using plain English queries

0
·53 views

A software developer has created an AI agent that automates Docker container troubleshooting by accepting plain-English questions such as 'why did the nginx container stop?' instead of requiring manual command-line investigation. The system combines three components: a FastMCP server that exposes specific Docker operations as callable tools, a locally running Gemma3 language model via Ollama, and a LangChain orchestration layer that manages the reasoning loop. Running entirely on-device via Ollama means sensitive container log data never leaves the user's machine, addressing a key privacy concern in production environments. Each tool in the MCP server is intentionally narrow in scope — for example, fetching logs only by container name — so the language model makes more reliable, unambiguous decisions rather than constructing arbitrary shell commands. The developer shared the project as a practical guide for others building similar LLM-powered DevOps automation tools, including bugs encountered during development.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Claude SEO: open-source plugin brings automated SEO audits to Claude Code

Claude SEO is a free, MIT-licensed open-source plugin for Claude Code, created by Agrici Daniel. It runs SEO audits from the terminal using 26 sub-skills and 19 specialized agents. The tool covers technical SEO, content and E-E-A-T analysis, Schema.org structured data, local and e-commerce SEO, and readiness for AI search and AI agents. It is aimed at SEO agencies, developers and marketers, and is installed by cloning its GitHub repository and running an install script.

0
ProgrammingDEV Community ·

Why AI coding agents' plans should be committed to the repo, not left in session folders

A developer argues that the plans AI coding agents generate are part of the deliverable and should live in a committed file on the task branch. Claude Code stores its plans in ~/.claude/plans/, a folder cleaned up automatically after 30 days by default, while GitHub Copilot CLI saves plan.md under a per-session folder. Codex's documentation does not say where its plans are stored, so they are assumed to live in the chat itself. Keeping plans with the session means reviewers typically cannot see the reasoning behind a change in the pull request. The author suggests committing the plan so reviewers and agents from any vendor can read and check the code against it.

0
ProgrammingDEV Community ·

Developer swaps headless Chrome for a lightweight Mermaid renderer to cut deploy size and cold starts

A developer needed flowcharts and sequence diagrams rendered as images within an agent pipeline. Their first approach used Puppeteer with headless Chrome, which added about 300MB to every container rebuild. The setup also slowed cold starts to several seconds and caused memory spikes that got smaller worker instances killed mid-render. They replaced it with a single-purpose endpoint that converts Mermaid syntax into base64 PNG or SVG output, requiring no local rendering stack. The developer concludes that the cost of general-purpose tools should be measured per deployment before adopting them as defaults, and reports that cold starts returned to acceptable levels.

0
ProgrammingDEV Community ·

Flutter ZIP-Code Autofill: Avoiding Common Bugs in Production

A developer built ZIP-code autofill for AI US Citizenship Test 2026, a Flutter app for green card holders, to replace a set of state-specific dropdowns during onboarding. The first version suffered from bugs found by real users, including treating ZIP codes as integers, which dropped leading zeros, and firing lookup requests on every keystroke. The article describes a hardened pattern that keeps ZIP codes as strings, accepts ZIP+4 input by normalizing to five digits, and debounces lookups until the input is complete and valid. It also covers a race condition where a stale response overwrote a corrected lookup, which is fixed with a generation counter that discards outdated results. The developer shares the approach so other engineers can avoid these pitfalls.