DOP-C02 Practice Question 81: CodeDeploy on Premises Registration
AWS Certified DevOps Engineer – Professional (DOP-C02) · Test 9 · question 1 of 10
A company runs a fleet of on-premises servers in a data center that has no plans to migrate to EC2 in the near term. The DevOps team wants to use AWS CodeDeploy to deploy application revisions to these servers alongside its existing EC2 deployments, using the same deployment groups and CodeDeploy agent workflow. What must the team do to make an on-premises server a valid deployment target for CodeDeploy?
Show answer and explanation
Answer:
CodeDeploy identifies on-premises instances through explicit registration: you create a configuration that associates the server with either an IAM user's static credentials or, for higher security, an IAM role assumed through AWS STS for periodically refreshed temporary credentials, then install the CodeDeploy agent using that configuration and tag the instance so deployment groups can target it the same way they target tagged EC2 instances.
B is wrong because Systems Manager hybrid activations register a server with Systems Manager for patching and Run Command, not with CodeDeploy; the two registration mechanisms are separate. C is wrong because Auto Scaling groups and launch templates only provision and manage EC2 instances, they cannot adopt a physical on-premises server. D is wrong because IAM instance profiles are an EC2-only construct delivered through the instance metadata service; an on-premises server has no metadata service to attach one to, which is exactly why CodeDeploy needs its own on-premises registration and credential model.