小编Ale*_*nov的帖子

如何从 terraform 状态打印出敏感值?

目标:我想打印出 的敏感值foo_resource.name.sensitive_field

\n

最初我尝试创建一个输出

\n
output "password" {\n  value       = foo_resource.name.sensitive_field\n}\n
Run Code Online (Sandbox Code Playgroud)\n

我得到了

\n
 Error: Output refers to sensitive values\n\xe2\x94\x82 \n\xe2\x94\x82   on main.tf line 186:\n\xe2\x94\x82  186: output "password" {\n\xe2\x94\x82 \n\xe2\x94\x82 To reduce the risk of accidentally exporting sensitive data that was intended to be only internal, Terraform requires that any root module output containing sensitive data be\n\xe2\x94\x82 explicitly marked as sensitive, to confirm your intent.\n\xe2\x94\x82 \n\xe2\x94\x82 If you do intend to export this data, annotate the …
Run Code Online (Sandbox Code Playgroud)

terraform

2
推荐指数
1
解决办法
9996
查看次数

标签 统计

terraform ×1