Terraform provisioners that require authentication can use which block?

Prepare for the HashiCorp Terraform Associate Exam with quizzes, flashcards, and multiple-choice questions. Each question includes hints and explanations. Boost your confidence and ace your exam!

Multiple Choice

Terraform provisioners that require authentication can use which block?

Explanation:
Provisioners that run on a remote resource rely on a connection block to authenticate and connect to that resource. When you attach a provisioner like remote-exec or file, Terraform uses the connection block to specify how to reach the target: the host, the user, and the authentication method (such as a private key or a password). It can also indicate the transport type, with SSH for Linux/Unix targets and WinRM for Windows targets. This connection information is exactly what enables Terraform to perform the provisioning steps on the remote machine. Other options don’t represent the standard mechanism Terraform uses for provisioning authentication, and there isn’t a standalone “ssh” or “credentials” block used in place of a connection block.

Provisioners that run on a remote resource rely on a connection block to authenticate and connect to that resource. When you attach a provisioner like remote-exec or file, Terraform uses the connection block to specify how to reach the target: the host, the user, and the authentication method (such as a private key or a password). It can also indicate the transport type, with SSH for Linux/Unix targets and WinRM for Windows targets. This connection information is exactly what enables Terraform to perform the provisioning steps on the remote machine. Other options don’t represent the standard mechanism Terraform uses for provisioning authentication, and there isn’t a standalone “ssh” or “credentials” block used in place of a connection block.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy