Question

Difficulty: MediumMethods of Deploying and Operating in AWS

A company needs to implement a simple, automated solution to stop all non-production Amazon EC2 instances every evening at 19:00. The systems administrator plans to write a shell script on an on-premises server that will execute API commands to filter and stop these instances. Which AWS tool or service is best suited to execute these commands directly from the shell script with minimal development effort?

  1. A
    AWS Management Console
  2. AWS Command Line Interface (CLI)Answer
  3. C
    AWS CloudFormation
  4. D
    AWS Software Development Kit (SDK)

Answer

AWS Command Line Interface (CLI)
The AWS Command Line Interface (CLI) is the most efficient choice because it allows the administrator to run commands directly from the shell script, requiring only simple syntax and no programming language compilation or runtime overhead.

Step-by-Step Solution

1
Identify the environment and execution requirement
The requirement specifies running commands directly from a local shell script.
This determines which interface is compatible with shell command execution.
2
Evaluate the development overhead of options
Using CLI commands in a bash script requires minimal setup compared to writing application code for an SDK.
The goal is to complete the automation task with the least development effort.
3
Select the tool that supports command-line automation
The AWS Command Line Interface (CLI) allows users to query resources and run management commands directly in shell scripts.
It matches the scripting requirement and minimizes code complexity.

Key Concept

Methods of Deploying and Operating in AWS
Rate this question