Terramate Metadata Variables
Terramate supports access to metadata of stacks, projects and the repository in the terramate
namespace.
Project Metadata
Project metadata is the same independent of a stack.
- The
terramate
object provides access to project metadata.version
(string) The Terramate version.stacks.list
(list of strings) List of all stacks inside the project. Each stack is represented by its absolute path relative to the project root. The list will be ordered lexicographically.root.path.fs.absolute
(string) The absolute path of the project root directory. Will be the same for all stacks.root.path.fs.basename
(string) The base name of the project root directory. Will be the same for all stacks.
Stack Metadata
- The
terramate.stack
object grants access to stack metadata and is only available in the stack context. The following keys are available in theterramate.stack
object and can be accessed withterramate.stack.<key>
, e.g.terramate.stack.id
.id
(string) The user-definedid
of the stack.name
(string) The user-definedname
of the stack.description
(string) The user-defineddescription
of the stack.tags
(list of string) The user-definedtags
of the stack.path
(object) An object defining the path of a stack within the repository in different waysabsolute
(string) The absolute path of the stack within the repository.basename
(string) The base name of the stack path.relative
(string) The relative path of the stack from the repository root.to_root
(string) The relative path from the stack to the repository root (upwards).
parent
(object): An object defining metadata for the immediate parent stack (if it exists):id
(string): The unique ID of the immediate parent stack.
Repository Metadata
- The
terramate.stacks
object grants access to a list of all stacks The following keys are available in theterramate.stacks.
object and can be accessed withterramate.stacks.<key>
, e.g.terramate.stack.list:
list
(list of string) A list of all absolute stack paths in the current repository.