The current implementation creates a local file to store the private key, but it's unfriendly to automation environment. Imagine that we run the Terraform script in an ephemeral runtime, all changes outside the tfstate that has been saved to the backend will be erased after the apply, the local file cannot be read when we run the plan or apply again. We need export the private key and mark it as sensitive instead.
The current implementation creates a local file to store the private key, but it's unfriendly to automation environment. Imagine that we run the Terraform script in an ephemeral runtime, all changes outside the tfstate that has been saved to the backend will be erased after the apply, the local file cannot be read when we run the plan or apply again. We need export the private key and mark it as sensitive instead.