Terraform outputs with "heredoc" syntax leaves <<EOT in file

I ran into the same problem today, the solution for me was to use -raw (terraform 0.15.4 at least):

    terraform output -raw kubeconfig > ~/.kube/config
2 Likes