{"id":50816036,"url":"https://github.com/ydah/docsterra","last_synced_at":"2026-06-13T09:33:41.140Z","repository":{"id":341196213,"uuid":"1167555147","full_name":"ydah/docsterra","owner":"ydah","description":"Parses Terraform (.tf) files and generates infrastructure design documentation in Markdown format.","archived":false,"fork":false,"pushed_at":"2026-02-28T12:50:31.000Z","size":109,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-02-28T16:34:06.765Z","etag":null,"topics":["docs","documentaion","generator","markdown","mermaid","ruby","terraform"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ydah.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-26T12:27:00.000Z","updated_at":"2026-02-28T12:49:48.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/ydah/docsterra","commit_stats":null,"previous_names":["ydah/docsterra"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/ydah/docsterra","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ydah%2Fdocsterra","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ydah%2Fdocsterra/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ydah%2Fdocsterra/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ydah%2Fdocsterra/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ydah","download_url":"https://codeload.github.com/ydah/docsterra/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ydah%2Fdocsterra/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34279898,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-13T02:00:06.617Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docs","documentaion","generator","markdown","mermaid","ruby","terraform"],"created_at":"2026-06-13T09:33:41.067Z","updated_at":"2026-06-13T09:33:41.132Z","avatar_url":"https://github.com/ydah.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Docsterra [![Gem Version](https://badge.fury.io/rb/docsterra.svg)](https://badge.fury.io/rb/docsterra) [![CI](https://github.com/ydah/docsterra/actions/workflows/main.yml/badge.svg)](https://github.com/ydah/docsterra/actions/workflows/main.yml)\n\n`docsterra` is a Ruby gem / CLI that parses Terraform (`.tf`) files and generates infrastructure design documentation in Markdown.\n\nCurrent implementation focuses on GCP Terraform resources and produces:\n\n- resource inventory tables\n- Mermaid network diagrams\n- cross-product dependency diagrams\n- security summaries (IAM / firewall / warnings)\n- cost-related spec summaries (non-billing estimate metadata)\n\n## Installation\n\n```bash\ngem install docsterra\n```\n\nOr from a Gemfile:\n\n```ruby\ngem \"docsterra\"\n```\n\n## Quick Start\n\nSingle Terraform root:\n\n```bash\ndocsterra generate ./terraform\n```\n\nMultiple products (cross-product dependency analysis enabled):\n\n```bash\ndocsterra generate ./product-a/terraform ./product-b/terraform ./shared/terraform -o ./docs/infrastructure.md\n```\n\nDry-run summary:\n\n```bash\ndocsterra check ./terraform\n```\n\n## CLI Reference\n\n### Commands\n\n```bash\ndocsterra generate [PATHS...]\ndocsterra check [PATHS...]\ndocsterra version\n```\n\n### Options\n\n- `-o`, `--output`: output markdown path (default: `./infrastructure.md`)\n- `-c`, `--config`: config file path (default: `.docsterra.yml`)\n- `-s`, `--sections`: comma-separated sections (`all`, `resources`, `network`, `security`, `cost`)\n- `-f`, `--format`: output format (currently only `markdown`)\n- `-v`, `--verbose`: verbose output\n- `--ignore`: ignore glob patterns (repeatable via Thor array syntax)\n\n## Library Usage\n\n```ruby\nrequire \"docsterra\"\n\ndoc = Docsterra.generate(\"./terraform\")\ndoc.save(\"./docs/infrastructure.md\")\nputs doc.to_markdown\n\nsummary = Docsterra.check(\"./terraform\")\nputs summary[:resource_count]\n```\n\n## Configuration (`.docsterra.yml`)\n\n```yaml\nproducts:\n  - name: \"Web Application\"\n    path: \"./product-web/terraform\"\n  - name: \"Shared Infrastructure\"\n    path: \"./shared/terraform\"\n    shared: true\n\noutput:\n  path: \"./docs/infrastructure.md\"\n  sections:\n    - resources\n    - network\n    - security\n    - cost\n\nresource_attributes:\n  google_compute_instance:\n    - machine_type\n    - zone\n    - labels.env\n\nignore:\n  - \"**/examples/**\"\n```\n\n## Output Example (Sections)\n\n- `## Overview`\n- `## Cross-Product Dependencies` (Mermaid)\n- `## {Product}`\n- `### Resources`\n- `### Network Configuration` (Mermaid)\n- `### Security Settings`\n- `### Cost Estimation`\n- `## Appendix`\n\n## Limitations\n\n- HCL parsing is best-effort. Unsupported expressions are preserved as `RawExpr` and rendered as text.\n- Remote modules are not parsed (metadata only).\n- Local modules are parsed recursively, but complex module evaluation/output resolution is not performed.\n- No real-time GCP pricing lookup; cost output is resource spec metadata only.\n- Terraform state / `terraform plan` JSON is not consumed.\n\n## Development\n\n```bash\nbundle install\nbundle exec rspec\n```\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fydah%2Fdocsterra","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fydah%2Fdocsterra","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fydah%2Fdocsterra/lists"}