Closed ACavuoto closed 9 months ago
Well, general Unix convention is that environment variables are in upper case. On Windows agents the variables will be set to uppercase regardless of what we do I believe (I know it works this way with variable groups).
We could make sure the documentation is accurate though. It might be worth considering changing the name of this command to something else since it's not really terraform output
exactly.
After looking at the documents: doesn't this describe everything? Are you looking somewhere else that isn't as clear?
Thanks @jason-johnson - It seems that I have missed that section in the documentation, sorry.
I still believe that it would be nice if there was an option to not prepend the TF_OUT_
prefix to the output variables
I'm planning to rework how the output variables are handled because currently they can't be referenced from other jobs or stages. I plan to leave the variables as is for those cases but I will probably need to stick with the TF_OUT_
convention for "within job" variables to avoid a clash.
Closing this one as a duplicate of #36
Hi, thanks for supporting this project.
I've installed this extension today and I had some headaches with the behaviour of the
output
command:https://github.com/jason-johnson/azure-pipelines-tasks-terraform/blob/6c5d1b5653d5977f2eca16d54e7ea1d7bd929825/tasks/terraform-cli/src/commands/tf-output.ts#L28
The logic here renames the output variables, prepending
TF_OUT_
and transforming them to uppercase. This feels like a deliberate choice, which I feel that breaks the implicit WYSIWYG expectation.I was wondering if you would consider adding a flag (something like
RenameOutputVariables
, default to true - to avoid breaking changes) to allow developers to get back control of output variable names.Also, if I may, I feel that documentation should be updated to reflect what this task is actually doing under the hood, as one doesn't necessarily expect that the terraform output CLI command would automatically:
Thanks a lot :)