1. DevOps Fundamentals
1. What is DevOps?
A) DevOps is a software development methodology that integrates development (Dev) and operations
(Ops) to improve collaboration, automation, and efficiency.
2. What are the key principles of DevOps?
A)
o Collaboration
o Automation
o Continuous Integration & Deployment
o Monitoring & Feedback
o Security & Compliance
3. How does DevOps differ from Agile?
A)Agile focuses on software development processes, while DevOps extends it to operations, ensuring
faster and reliable delivery.
4. What are the key benefits of DevOps?
A)
o Faster software releases
o Improved collaboration
o Higher efficiency and scalability
o Better system reliability
5. What are the key DevOps tools?
A)
o CI/CD: Jenkins, GitLab CI, GitHub Actions
o Containerization: Docker, Podman
o Orchestration: Kubernetes, OpenShift
o Monitoring: Prometheus, Grafana
o Configuration Management: Ansible, Puppet, Chef
o Version Control: Git
2. Version Control & Git
6. What is Git?
A) Git is a distributed version control system for tracking source code changes.
7. Difference between Git and GitHub/GitLab?
A) Git is a VCS, whereas GitHub/GitLab are web-based platforms providing repositories with
collaboration features.
8. What is the difference between git pull and git fetch?
A)
o git fetch: Downloads changes but doesn’t merge.
o git pull: Fetches and merges changes into the working branch.
9. Explain Git branching strategies.
A)
o Feature Branching: Develop features in isolated branches.
o Gitflow: Uses main, develop, feature, release, and hotfix branches.
o Trunk-based development: Continuous integration into main.
10. How do you resolve a merge conflict in Git?
A)
o Identify conflicts using git status.
o Manually edit the conflicting files.
o Add (git add) and commit (git commit -m “Resolved conflict”) the resolved files.
3. CI/CD (Jenkins, GitLab CI/CD, GitHub Actions)
11. What is Continuous Integration (CI)?
A) CI automates code integration from multiple developers into a shared repository.
12. What is Continuous Deployment (CD)?
A)
CD automates software delivery from testing to production.
13. Explain Jenkins Pipeline.
A)
o A Declarative Pipeline defines the entire CI/CD process in Jenkinsfile.
o A Scripted Pipeline provides greater flexibility but requires Groovy scripting.
14. How do you secure Jenkins?
A)
o Use Role-Based Access Control (RBAC).
o Encrypt secrets using Jenkins credentials.
o Use HTTPS and limit plugin vulnerabilities.
15. What are GitHub Actions and their advantages?
A)
o A CI/CD automation tool integrated with GitHub.
o Advantages: Easy setup, built-in marketplace, YAML-based workflows.
4. Configuration Management (Ansible, Puppet, Chef)
16. What is Configuration Management in DevOps?
A)
Managing system configurations to ensure consistency and scalability.
17. How does Ansible differ from Puppet and Chef?
A)
o Ansible: Agentless, YAML-based, push model.
o Puppet: Agent-based, uses Puppet DSL, pull model.
o Chef: Uses Ruby DSL, agent-based.
18. What is an Ansible Playbook?
A) A YAML file defining automation tasks.
19. Explain Infrastructure as Code (IaC).
A) Automating infrastructure provisioning using code (e.g., Terraform, Ansible).
20. What is an Ansible role?
A) A structured way to organize Ansible Playbooks.
5. Containers & Orchestration (Docker, Kubernetes)
21. What is Docker?
A) Docker is a containerization platform that packages applications with dependencies.
22. What is a Dockerfile?
A) A script containing instructions to build a Docker image.
23. What is Kubernetes?
A) An orchestration platform for managing containerized applications.
24. What are Kubernetes Pods?
A) The smallest deployable unit in Kubernetes, containing one or more containers.
25. What is Helm in Kubernetes?
A) A package manager for Kubernetes that simplifies application deployment.
6. Cloud & Infrastructure as Code (AWS, Azure, GCP, Terraform)
26. What is Terraform?
A) An open-source IaC tool for managing cloud infrastructure declaratively.
27. What is the difference between Terraform and CloudFormation?
A)
o Terraform: Multi-cloud, state management, declarative.
o CloudFormation: AWS-specific, integrated with AWS services.
28. Explain the Terraform state file.
A) Stores infrastructure state to track changes.
29. What is an AWS IAM role?
A) A set of permissions for AWS services to access resources securely.
30. What is auto-scaling in AWS?
A) Automatically adjusting the number of instances based on demand.
7. Monitoring & Logging (Prometheus, Grafana, ELK Stack)
31. What is Prometheus?
A) An open-source monitoring system for collecting and querying time-series data.
32. What is Grafana used for?
A) A visualization tool for monitoring metrics.
33. Explain the ELK Stack.
A)
o Elasticsearch: Search engine
o Logstash: Log ingestion
o Kibana: Visualization
34. What is observability?
A) The ability to measure system health via logs, metrics, and traces.
35. What are service-level objectives (SLOs)?
A) Targets for system performance and availability.
8. Security in DevOps (DevSecOps)
36. What is DevSecOps?
A) Integrating security into DevOps workflows.
37. What is OWASP?
A) Open Web Application Security Project – provides security guidelines.
38. How do you secure a containerized environment?
A)
o Use minimal base images.
o Implement RBAC in Kubernetes.
o Scan images for vulnerabilities.
39. What is Shift-Left Security?
A) Incorporating security early in the software development lifecycle.
40. What are secrets management tools?
A) HashiCorp Vault, AWS Secrets Manager, Kubernetes Secrets.
9. SRE & Reliability Engineering
41. What is Site Reliability Engineering (SRE)?
A) A discipline that applies software engineering to infrastructure operations.
42. What are SLAs, SLOs, and SLIs?
A)
o SLA: Service Level Agreement
o SLO: Service Level Objective
o SLI: Service Level Indicator
43. What is Chaos Engineering?
A) The practice of testing system resilience through controlled failures.
44. What is an Error Budget?
A) The acceptable downtime limit before affecting SLOs.
45. What are blameless postmortems?
A) Incident reviews focused on learning rather than blaming.
10. Advanced CI/CD Concepts
46. How do you implement Blue-Green Deployment?
A)
o Maintain two environments (Blue = live, Green = new).
o Switch traffic after testing Green.
47. What is Canary Deployment?
A)
o Gradual release to a small subset of users before full rollout.
48. What is a Rolling Update?
A)
o Gradual replacement of old instances with new ones without downtime.
49. How do you handle secrets in CI/CD pipelines?
A)
o Use environment variables, HashiCorp Vault, or AWS Secrets Manager.
50. How do you prevent deployment failures?
A)
o Implement automated testing, rollback strategies, and feature flags.