{"id":13505831,"url":"https://elementtech.github.io/terracove/","last_synced_at":"2025-03-30T00:31:38.858Z","repository":{"id":152243035,"uuid":"625306431","full_name":"ElementTech/terracove","owner":"ElementTech","description":"Recursively test a directory tree for Terraform diffs and coverage","archived":false,"fork":false,"pushed_at":"2023-07-18T07:08:07.000Z","size":414,"stargazers_count":49,"open_issues_count":9,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-19T16:51:29.655Z","etag":null,"topics":["iac","infrastructure","infrastructure-as-code","terraform","terragrunt","terratest","testing"],"latest_commit_sha":null,"homepage":"https://elementtech.github.io/terracove/","language":"Go","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/ElementTech.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null},"funding":{"github":null,"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":"https://www.buymeacoffee.com/elementtech"}},"created_at":"2023-04-08T17:49:31.000Z","updated_at":"2024-12-23T15:32:57.000Z","dependencies_parsed_at":"2024-01-03T02:28:53.546Z","dependency_job_id":"578c29a5-8ee0-4189-bc71-31f29ac63924","html_url":"https://github.com/ElementTech/terracove","commit_stats":null,"previous_names":["elementtech/terracove"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ElementTech%2Fterracove","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ElementTech%2Fterracove/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ElementTech%2Fterracove/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ElementTech%2Fterracove/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ElementTech","download_url":"https://codeload.github.com/ElementTech/terracove/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246262490,"owners_count":20749170,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["iac","infrastructure","infrastructure-as-code","terraform","terragrunt","terratest","testing"],"created_at":"2024-08-01T00:01:14.912Z","updated_at":"2025-03-30T00:31:33.838Z","avatar_url":"https://github.com/ElementTech.png","language":"Go","funding_links":["https://www.buymeacoffee.com/elementtech"],"categories":["Tools"],"sub_categories":["Community providers"],"readme":"\n\u003ch1 align=\"center\"\u003e\n  \u003cimg src=\"./assets/logo/logo.png\" alt=\"terracove\" width=\"200\"\u003e\n\u003c/h1\u003e\n\n\u003ch4 align=\"center\"\u003eA recursive terraform repository tester powered by \u003ca href=\"https://terratest.gruntwork.io/\" target=\"_blank\"\u003eTerratest\u003c/a\u003e.\u003c/h4\u003e\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://github.com/elementtech/terracove/actions/workflows/test.yml/badge.svg\" alt=\"drawing\"/\u003e\n\u003cimg src=\"https://github.com/elementtech/terracove/actions/workflows/lint.yml/badge.svg\" alt=\"drawing\"/\u003e\n\u003cimg src=\"https://codecov.io/gh/elementtech/terracove/branch/main/graph/badge.svg\" alt=\"drawing\"/\u003e\n\u003cimg src=\"https://goreportcard.com/badge/elementtech/terracove\" alt=\"drawing\"/\u003e\n\u003cimg src=\"https://img.shields.io/github/v/release/elementtech/terracove\" alt=\"drawing\"/\u003e\n\u003cimg src=\"https://img.shields.io/github/downloads/elementtech/terracove/total.svg\" alt=\"drawing\"/\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#key-features\"\u003eKey Features\u003c/a\u003e •\n  \u003ca href=\"#install\"\u003eInstall\u003c/a\u003e •\n  \u003ca href=\"#usage\"\u003eUsage\u003c/a\u003e •\n  \u003ca href=\"#quickstart\"\u003eQuickstart\u003c/a\u003e •\n  \u003ca href=\"#credits\"\u003eCredits\u003c/a\u003e •\n  \u003ca href=\"#support\"\u003eSupport\u003c/a\u003e •\n  \u003ca href=\"#license\"\u003eLicense\u003c/a\u003e\n\u003c/p\u003e\n\n![screenshot](./assets/example.png)\n\n\u003chr\u003e\n\n\n## Key Features\n\n* Test in parallel multiple directory paths\n* Export Results:\n  * [junit](./examples/terracove.xml) with `--junit`\n  * [json](./examples/terracove.json) summary with `--json`\n  * [html](./examples/terracove.html) report with `--html`\n* Generate `%` coverage for each module and root directory\n* Ignore Errors and Empty Modules\n* Supports [terraform](https://www.terraform.io/) and [terragrunt](https://terragrunt.gruntwork.io/) in the same directory tree\n\n\n## Install\n\nThe recommended way to install on MacOS is via brew:\n\n```sh\nbrew tap elementtech/elementtech\nbrew install terracove\n```\n\nIf you'd like to use Docker, you can use the official image:\n```sh\ndocker run --rm -v $(pwd):/data ghcr.io/elementtech/terracove /data --json --junit --html\n```\n\nOr, you can install directly from release:\n```sh\ncurl -sS https://raw.githubusercontent.com/elementtech/terracove/main/install.sh | bash\n```\n## Usage\n\n```sh\nUsage:\n  terracove [paths]... [flags]\n\nFlags:\n  -e, --exclude strings         Exclude directories while parsing tree\n  -h, --help                    help for terracove\n  -w, --html                    Output HTML Report\n      --ignore-empty            Ignore Modules with 0 Resources\n      --ignore-errors           Ignore Planning Errors\n  -j, --json                    Output JSON\n  -x, --junit                   Output Junit XML\n      --minimal                 Don't Append Raw/JSON Plan to the Exported Output\n      --o-html string           Output HTML Report File (default \"terracove.html\")\n      --o-json string           Output JSON File (default \"terracove.json\")\n      --o-junit string          Output Junit XML File (default \"terracove.xml\")\n  -t, --validate-tf-by string   validate terraform by the existence of [filename] in a directory (default \"main.tf\")\n  -g, --validate-tg-by string   validate terragrunt by the existence of [filename] in a directory (default \"terragrunt.hcl\")\n  -v, --version                 version for terracove\n```\n\n## Quickstart\n\u003e Note that you must have terraform/terragrunt binaries installed on your machine\n\n\u003e The [examples](./examples) directory contains **4 modules**. 2 of them are [terraform](./examples/terraform) and 2 are [terragrunt](./examples/terragrunt). \n\u003e \n\u003e **Oh no!** It appears some of them have some problems. Let's see exactly what is going on.\n\u003e Clone this repository and give it a try.\n\n```sh\ngit clone https://github.com/elementtech/terracove.git\ncd terracove\nterracove --minimal --junit --json --html . \n# . == examples == examples/terraform examples/terragrunt\n```\n\nOpen the **terracove.xml**, **terracove.json** or **terracove.html** and observe the results. You should see the following:\n\n```json\n[\n {\n  \"Timestamp\": \"1984-01-01T19:32:58+05:00\",\n  \"Path\": \".\",\n  \"Results\": [\n   {\n    \"Path\": \"examples/terragrunt/no-resources\",\n    \"ResourceCount\": 0,\n    \"Coverage\": 100,\n    ...\n   },\n   {\n    \"Path\": \"examples/terragrunt/error\",\n    \"Coverage\": 0,\n    ...\n   },\n   {\n    \"Path\": \"examples/terraform/tfstate-diff\",\n    \"ResourceCount\": 2,\n    \"ResourceCountDiff\": 1,\n    \"Coverage\": 50,\n    ...\n   },\n   {\n    \"Path\": \"examples/terraform/success\",\n    \"ResourceCount\": 2,\n    \"ResourceCountExists\": 2,\n    \"Coverage\": 100,\n    ...\n   }\n  ],\n  \"Coverage\": 62.5\n }\n]\n```\n\n\n## Credits\n\nThis project uses or is inspired by the following open source projects:\n\n- [golang-cli-template](https://github.com/FalcoSuessgott/golang-cli-template)\n- [terratest](https://terratest.gruntwork.io/)\n- [docker-terragrunt](https://github.com/devops-infra/docker-terragrunt)\n- [junit2html](https://github.com/kitproj/junit2html)\n## Support\n\n\u003ca href=\"https://www.buymeacoffee.com/elementtech\" target=\"_blank\"\u003e\u003cimg src=\"https://www.buymeacoffee.com/assets/img/custom_images/purple_img.png\" alt=\"Buy Me A Coffee\" style=\"height: 41px !important;width: 174px !important;box-shadow: 0px 3px 2px 0px rgba(190, 190, 190, 0.5) !important;-webkit-box-shadow: 0px 3px 2px 0px rgba(190, 190, 190, 0.5) !important;\" \u003e\u003c/a\u003e\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/elementtech.github.io%2Fterracove%2F","html_url":"https://awesome.ecosyste.ms/projects/elementtech.github.io%2Fterracove%2F","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/elementtech.github.io%2Fterracove%2F/lists"}