-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Issue with metadata interpretation in stack configuration #692
Comments
Hi @joshuacook-tamu, thanks for sharing. The problem is that We will for sure improve the error message in this case ;) We are actually currently refactoring all output to improve the user experience. A solution to achieve what you want is to use absolute stack path as so just using stack {
name = "test vm"
after = [
"/stacks/resources/vm-admin-keypair",
"/stacks/resources/vm-security-group",
]
} should do the trick (or |
Thanks for the response. I'll do it the way you suggest. Perhaps this could be converted to a feature request as I would suggest that you support this use case. If you do not plan to support it, at least document the fact that the Again, thanks for your quick response! |
Added this information on the stack docs on #693. @joshuacook-tamu on the apparent inconsistency, it is not without reason. We initially avoided allowing globals and metadata on the stack block because allowing it will introduce the possibility of circular definitions, which are tricky (but possible) to detect and debug, so we opted to constrain the stack block to avoid issues. But on the future we may provide at least a subset of metadata that is safe (project wide metadata, non stack dependent), or even allow global references and deal with circular definitons. I would suggest we close this as it is not a bug and maybe create a different issue as a feature request. |
I agree that this is not a bug since you designed it this way. I'll try to open a feature request instead. Thanks for the explanation! |
Describe the bug
I am attempting to define orchestration / dependency relationships between stacks. I defined it via the
after
statement in the stack config and used the metadata such as${terramate.stack.path.to_root}
. Terramate fails to evaluate stating there is no variable named "terramate"To Reproduce
Steps to reproduce the behavior:
Note, I tried two different approaches above, but both fail with the same error.
terramate list
Expected behavior
A clear and concise description of what you expected to happen.
I expected the variable interpolation to work here as it does in multiple other configuration elements within Terramate. Of course, it will work if I uncomment the lines above with the
../..
and comment out the lines with the Terramate metadata elements. This is what I have done for now.Log Output
Add logs from Terramate to help debug your problem.
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: