How should the SysOps administrator use AWS CloudFormation to create a solution?
Use Amazon EC2 user data in a CloudFormation template.
Use nested stacks to provision resources.
Use parameters in a CloudFormation template.
Use stack policies to provision resources.
Explanations:
While Amazon EC2 user data can automate instance configurations at launch, it does not facilitate reusability of the CloudFormation template across multiple environments. User data is environment-specific and doesn’t help in managing infrastructure as code in a flexible manner.
Nested stacks allow you to organize resources into separate templates for better management but do not inherently address the need for a single reusable template. They can complicate deployments if not managed carefully and do not directly allow parameterization for different environments.
Using parameters in a CloudFormation template allows the SysOps administrator to define input values that can be changed at runtime. This enables the same template to be reused across different environments (like development, testing, and production) by simply changing parameter values.
Stack policies control whether updates can be made to certain resources during stack updates but do not provide a mechanism for reusing a template across multiple environments. They are more about protecting resources during changes rather than enabling flexibility in template usage.