Skip to content

Basics Questions

How to use these interview questions

🧠 Read each question carefully.

Try answering it yourself before expanding the answer to compare with the ideal response.

Level: Basics

🟒 Foundational interview questions.

Focus on core concepts, definitions, and building blocks.

1. Which AWS service is primarily used to orchestrate and model different stages of your software release process?

AWS CodePipeline.

CodePipeline acts as the "conductor" of your CI/CD workflow, managing the flow from source to build to deploy.

2. What is the primary function of AWS CodeBuild?

To compile source code, run tests, and produce software packages.

CodeBuild is a fully managed build service that scales continuously and processes multiple builds concurrently.

3. Which file defines the build instructions for AWS CodeBuild?

buildspec.yml.

The buildspec.yml file contains the commands (install, pre_build, build, post_build) and settings used by CodeBuild to run your build.

4. Which file defines the deployment instructions for AWS CodeDeploy?

appspec.yml.

The appspec.yml file is used by CodeDeploy to determine what to install and which lifecycle hooks to run (e.g., ApplicationStop, BeforeInstall, AfterInstall).

5. What does "Infrastructure as Code" (IaC) mean?

Managing and provisioning infrastructure through machine-readable definition files rather than physical hardware configuration or interactive configuration tools.

βœ” Key Benefit: Allows you to automate infrastructure provisioning, ensuring consistency and version control.

6. Which AWS service allows you to define infrastructure using JSON or YAML templates?

AWS CloudFormation.

CloudFormation provides a common language to describe and provision all the infrastructure resources in your cloud environment.

7. In CloudFormation, what is a "Stack"?

A collection of resources managed as a single unit.

When you create a stack, AWS CloudFormation provisions all the resources described in your template. If the stack is deleted, all resources are deleted together.

8. Where should you securely store database passwords and API keys referenced in your pipeline?

AWS Secrets Manager or AWS Systems Manager Parameter Store.

βœ” Best Practice: Never hardcode secrets in your code. Use managed services to inject them dynamically at runtime.

9. Which Source Control service is hosted by AWS?

AWS CodeCommit.

CodeCommit is a secure, highly scalable, managed source control service that hosts private Git repositories.

10. What is a "Blue/Green Deployment"?

A technique that shifts traffic between two identical environments running different versions of the application.

βœ” Benefit: Reduces downtime and risk by running two environments in parallel. If the new version fails, you can switch traffic back instantly.

11. Which service would you use to centralize logs from all your EC2 instances?

Amazon CloudWatch Logs.

The CloudWatch unified agent can push logs from EC2 instances to CloudWatch Logs groups for centralized storage, searching, and analysis.

12. What is the purpose of the "Install" lifecycle event in CodeDeploy?

It copies the revision files from the temporary location to the final destination folder on the instance.

13. Which CodePipeline action type is used to add a step for manual verification before deploying to production?

Manual Approval.

A Manual Approval action pauses the pipeline execution until someone approves it via the console.

14. How can you trigger a Lambda function automatically when a file is uploaded to an S3 bucket?

Configure an S3 Event Notification.

S3 can publish events (like s3:ObjectCreated) to Lambda, allowing for event-driven workflows logic (e.g., enable thumbnail generation when an image is uploaded).

15. What is the main benefit of using Docker containers in a DevOps workflow?

Consistency across environments.

Containers package code and dependencies together, ensuring that the application runs the same on a developer's laptop, testing server, and production.

16. Which service is a fully managed container orchestration service compatible with Kubernetes?

Amazon EKS (Elastic Kubernetes Service).

EKS manages the Kubernetes control plane for you, making it easier to run standard K8s clusters without managing the master nodes.

17. What is "Continuous Integration" (CI)?

The practice of merging code changes into a central repository frequently, followed by automated builds and tests.

βœ” Goal: Find integration bugs early.

18. Which CloudFormation section allows you to pass values into the template at runtime?

Parameters.

Parameters enable you to input custom values (like KeyPairName, InstanceType, or Environment) when you create or update a stack.

19. What does the "Resources" section of a CloudFormation template contain?

The AWS resources (e.g., EC2 Instance, S3 Bucket) you want to create.

βœ” Note: The Resources section is the only required section in a template.

20. Which tool позволяСт you to treat your infrastructure as code using a familiar programming language (Python, TypeScript, Java)?

AWS CDK (Cloud Development Kit).

CDK allows you to define cloud resources using modern programming languages and synthesizes them into CloudFormation templates.


πŸ§ͺ Ready to test yourself?

πŸ‘‰ Take the AWS DevOps Engineer Basics Quiz

πŸ“¬ DevopsPilot Weekly β€” Learn DevOps, Cloud & Gen AI the simple way.
πŸ‘‰ Subscribe here