DVA-C02 · Question #496
A developer needs to write an AWS CloudFormation template on a local machine and deploy a CloudFormation stack to AWS. What must the developer do to complete these tasks?
The correct answer is C. Install the AWS CLI, Configure the AWS CLI by using an IAM user access key and secret key.. The AWS CLI is the standard tool for deploying CloudFormation stacks from a local machine, and it authenticates using an IAM user's access key ID and secret access key stored in the credential configuration.
Question
A developer needs to write an AWS CloudFormation template on a local machine and deploy a CloudFormation stack to AWS. What must the developer do to complete these tasks?
Options
- AInstall the AWS CLI. Configure the AWS CLI by using an IAM user name and password.
- BInstall the AWS CLI. Configure the AWS CLI by using an SSH key.
- CInstall the AWS CLI, Configure the AWS CLI by using an IAM user access key and secret key.
- DInstall an AWS software development kit (SDK). Configure the SDK by using an X.509 certificate.
How the community answered
(53 responses)- A8% (4)
- B4% (2)
- C87% (46)
- D2% (1)
Why each option
The AWS CLI is the standard tool for deploying CloudFormation stacks from a local machine, and it authenticates using an IAM user's access key ID and secret access key stored in the credential configuration.
The AWS CLI does not authenticate using an IAM username and password; those credentials are for the AWS Management Console only, not programmatic API access.
SSH keys are used for EC2 instance access, not for authenticating AWS CLI API calls to services like CloudFormation.
The AWS CLI uses IAM access key credentials (access key ID + secret access key) configured via `aws configure` or environment variables to sign API requests. CloudFormation stack deployment via `aws cloudformation deploy` or `create-stack` requires these programmatic credentials, which are the standard authentication mechanism for CLI-based interactions.
X.509 certificates are used for SOAP-based AWS API calls, which are largely deprecated; the AWS CLI does not use certificates for authentication, and an SDK alone is not the required tool for CloudFormation deployments.
Concept tested: AWS CLI authentication with IAM access keys for CloudFormation
Source: https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-files.html
Community Discussion
No community discussion yet for this question.