Skip to content

Add configuration documentation generator#57

Open
dcmcand wants to merge 2 commits intomainfrom
feature/config-doc-generator
Open

Add configuration documentation generator#57
dcmcand wants to merge 2 commits intomainfrom
feature/config-doc-generator

Conversation

@dcmcand
Copy link
Contributor

@dcmcand dcmcand commented Feb 5, 2026

Closes

Closes #40

Description

Adds a documentation generator (cmd/docgen) that parses Go config structs using go/ast and generates markdown documentation. Also adds comprehensive doc comments to all provider config structs.

New files:

  • cmd/docgen/ - Documentation generator with full test coverage
  • docs/configuration/ - Auto-generated markdown docs

Updated files:

  • Provider configs with field-level doc comments (AWS, GCP, Azure, Local, Cloudflare)
  • Makefile - Added docs target
  • README.md and docs/README.md - Added Configuration Reference sections

How to Test

  1. Run make docs to regenerate documentation
  2. Run go test ./cmd/docgen/... to verify tests pass
  3. Check docs/configuration/ for generated markdown files

Implements GitHub issue #40 - generates markdown documentation from Go
config structs using go/ast parsing.

Features:
- Parses Go source files to extract struct definitions, field types,
  yaml tags, and doc comments
- Generates markdown tables with field name, YAML key, type, required
  status, and description
- Adds comprehensive doc comments to all provider config structs
- Adds `make docs` target for easy regeneration

Generated docs cover:
- Core configuration (project name, provider, domain, certificates)
- AWS provider (EKS, VPC, node groups, EFS)
- GCP provider (GKE, VPC, node pools, GPUs)
- Azure provider (AKS, networking, node pools)
- Local provider (K3s, kind, minikube)
- Cloudflare DNS provider
- Git repository configuration for ArgoCD
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Generate config documentation from Go structs

1 participant