DEV Community

Cover image for Ops Whisperer 🌩️: Speaking Infrastructure into Existence
Salek Masud Parvez
Salek Masud Parvez

Posted on

Ops Whisperer 🌩️: Speaking Infrastructure into Existence

GitHub Copilot CLI Challenge Submission

This is my submission for the GitHub Copilot CLI Challenge

What I Built

I created Ops Whisperer, a friendly AI-powered CLI tool that turns your natural language ideas into ready-to-use infrastructure code.

Let's be real: even seasoned engineers sometimes freeze trying to recall the exact YAML structure for a Kubernetes Ingress, the right multi-stage build in a Dockerfile, or the proper Terraform resource syntax. We end up Googling, copy-pasting from old projects, or fighting mysterious indentation bugs.

Ops Whisperer fixes that pain. Just describe what you want in plain English β€” and it instantly generates clean, production-ready configuration files for you, right in your terminal.

Currently supported:

  • 🐳 Docker β€” Dockerfiles and docker-compose.yml stacks
  • ☸️ Kubernetes β€” Deployments, Services, Ingresses, ConfigMaps, and more
  • πŸ—οΈ Terraform β€” IaC resources, modules, providers
  • πŸ’» Bash β€” Safe, complex shell scripts and one-liners

It includes a built-in Safety Rail system (heavily assisted by Copilot) that scans output and blocks truly dangerous patterns β€” no accidental rm -rf / surprises.

Try It Out

  npm install -g ops-whisperer
Enter fullscreen mode Exit fullscreen mode

Demo Screenshot

Ops Whisperer CLI demo β€” generating a Dockerfile from natural language

(Tip: Replace this placeholder with your actual screenshot of running something like ops "create a Node.js Dockerfile with multi-stage build")

My Experience with GitHub Copilot CLI

Building an AI CLI tool using another AI CLI tool felt wonderfully meta πŸ˜„.

The hardest parts of CLI development are rarely the core logic β€” it's all the surrounding glue: argument parsing, proper exit codes, colored output, error handling, streams… you name it.

GitHub Copilot CLI (gh copilot) became my always-available terminal pair programmer. No more context-switching to browser tabs or docs β€” everything stayed in the flow.

Here’s how it supercharged my workflow:

1. Instant project scaffolding

Setting up a modern Node.js CLI with ESM, commander, and inquirer usually eats 15–30 minutes of boilerplate hunting.

I just asked:

gh copilot suggest "create a node.js cli entry point using commander and inquirer with ESM imports"
Enter fullscreen mode Exit fullscreen mode

Boom β€” perfect program.version(), .option(), .parse() structure, correct ESM config, the works. Ready in under 2 minutes.

2. Bullet-proof Safety Rails (the hardest part)

Blocking dangerous commands (rm -rf, mkfs, fork bombs, device writes, etc.) reliably is tricky β€” regex hell.

I asked Copilot to help:

gh copilot suggest "javascript regex to detect dangerous linux commands like rm -rf or mkfs or > /dev/sda"
Enter fullscreen mode Exit fullscreen mode

It gave me a solid, explainable pattern I could trust and extend. Huge time-saver and peace of mind.

3. Debugging without leaving the terminal

Hit a weird execa stdio error during interactive prompts?

Piped it straight to:

gh copilot explain "Error: stdio must be of type ..."
Enter fullscreen mode Exit fullscreen mode

Instant clear explanation + suggested fix. Bug squashed in minutes instead of 30+ Googling.

Bonus wins

  • Quick ora spinner + chalk color chaining for that premium feel
  • Proper stream handling for child processes
  • ANSI-friendly output formatting

Bottom line: Copilot CLI didn't just autocomplete code β€” it acted as on-demand docs expert, regex wizard, and logic validator. It let me spend way more time on the interesting part (the AI whisperer logic) and way less on Node.js CLI ceremony.

Thanks to GitHub Copilot CLI, I stayed deep in flow and shipped faster.

Would love any feedback or ideas β€” feel free to star the repo or open issues! πŸš€




This version feels more conversational, engaging, and professional while keeping your original voice and key points. Good luck with the challenge!
Enter fullscreen mode Exit fullscreen mode

Top comments (0)