indexer
indexer makes Stategraph Orchestration generate parts of the repository configuration from the repository structure and your Terraform code. You write less configuration by hand, and it helps make sure that the correct directories run on plan and apply.
Default Configuration
indexer:
enabled: false
Keys
| Key | Type | Description |
|---|---|---|
enabled |
boolean | Turns on the indexer. Default is false. |
build_tag |
string | The container image that the runner pulls to execute the indexer. Default is ghcr.io/terrateamio/code-indexer:latest. Set it to pin a version or to use a mirror. |
Functionality
The indexer maps the Terraform modules, the directories that reference them, and the symbolic links in the repository. Orchestration uses this map to find the directories that run on plan and apply:
- Modules: when a
moduleblock references a directory, a change to that module directory does not run the module directory. It runs the directories that reference the module. - Symlinks: Orchestration treats a symbolic link as the file or directory that it references.
Usage
- When the indexer is enabled, it runs on a change if no index exists for that commit hash.
- To force a new index, comment
stategraph indexon a pull request. - To review the configuration that the indexer generated, comment
stategraph repo-configon the pull request. It shows how Orchestration reads your repository structure and Terraform code.