Created
June 24, 2020 18:20
-
-
Save gmirsky/6df353ed265c069a1e30fb63e8fa3a19 to your computer and use it in GitHub Desktop.
terraform get current user id
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| data "aws_caller_identity" "current" {} | |
| output "account_id" { | |
| value = "${data.aws_caller_identity.current.account_id}" | |
| } | |
| output "caller_arn" { | |
| value = "${data.aws_caller_identity.current.arn}" | |
| } | |
| output "caller_user" { | |
| value = "${data.aws_caller_identity.current.user_id}" | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment