Practice Labs
Use a free local setup (Docker, kind) or a sandbox cloud account with a budget alert. Delete lab resources when finished.
| # | Lab | Hint |
| 1 | Write a Bash script that checks disk usage, memory and a list of URLs, exits non-zero on a problem and runs from cron | set -euo pipefail, curl -fsS, df -h |
| 2 | Create a Git repo, make a feature branch, cause and resolve a merge conflict, then clean up with an interactive rebase | git rebase -i, git merge --abort |
| 3 | Containerize an app with a multi-stage, non-root Dockerfile and compare image sizes | docker history, dive |
| 4 | Run an app, a database and a cache with Docker Compose using health checks and a volume | depends_on: condition: service_healthy |
| 5 | Create a kind cluster, deploy with a Deployment and Service, do a rolling update and rollback | kubectl rollout undo |
| 6 | Add ConfigMap, Secret, probes, resource limits and an HPA. Generate load and observe scaling | kubectl top, hey or k6 |
| 7 | Write a GitHub Actions pipeline: test, scan, build, push, deploy. Make it fail on a vulnerable dependency | trivy, matrix, caching |
| 8 | Create a VPC, instance and security group with Terraform. Use a remote backend and a module | S3 backend, terraform plan -out |
| 9 | Configure two servers with an Ansible role, run it twice and prove idempotency | --check --diff |
| 10 | Install Prometheus and Grafana, instrument an app, graph p95 latency and alert on error rate | histogram_quantile, Alertmanager |
| 11 | Install Argo CD, deploy an app from Git, break it by hand and watch self-heal | selfHeal: true |
| 12 | Add Kyverno policies and a canary rollout with automated analysis, then simulate an incident and write a postmortem | Argo Rollouts AnalysisTemplate |
Cheat Sheet: Linux
| Task | Command |
| Disk, memory, load | df -h, free -h, uptime, top |
| Find big folders | du -sh * | sort -h |
| Search text | grep -rin "error" /var/log/app/ |
| Follow log | tail -f app.log, journalctl -u svc -f |
| Listening ports | ss -tulpn |
| Service control | systemctl status|start|stop|restart|enable svc |
| Permissions | chmod 640 file, chown user:group file |
| Remote copy / sync | scp, rsync -avz |
| Processes | ps aux | grep x, kill -15 PID |
Cheat Sheet: Git
| Task | Command |
| Status, diff, log | git status, git diff, git log --oneline --graph --all |
| Stage and commit | git add -p, git commit -m "msg" |
| Branch | git switch -c name, git branch -d name |
| Update branch | git fetch, git rebase origin/main |
| Undo safely | git revert SHA, git restore file |
| Recover | git reflog, git reset --hard SHA |
| Save work | git stash push -m x, git stash pop |
| Tag release | git tag -a v1.0.0 -m x && git push origin v1.0.0 |
Cheat Sheet: Docker
| Task | Command |
| Run | docker run -d --name web -p 8080:80 -e K=v -v data:/path img |
| List, logs, shell | docker ps -a, docker logs -f web, docker exec -it web sh |
| Build and push | docker build -t repo/app:1.0 ., docker push repo/app:1.0 |
| Compose | docker compose up -d --build, docker compose logs -f, docker compose down |
| Clean | docker system prune -a, docker volume prune |
| Inspect | docker inspect web, docker stats |
Cheat Sheet: kubectl
| Task | Command |
| Context and namespace | kubectl config get-contexts, kubectl config set-context --current --namespace=dev |
| List | kubectl get pods -A -o wide, kubectl get all |
| Inspect | kubectl describe pod X, kubectl get events --sort-by=.lastTimestamp |
| Logs and shell | kubectl logs X --previous, kubectl exec -it X -- sh |
| Create YAML fast | kubectl create deploy web --image=nginx --dry-run=client -o yaml |
| Apply / delete | kubectl apply -f x.yaml, kubectl delete -f x.yaml |
| Scale and update | kubectl scale deploy web --replicas=5, kubectl set image deploy/web c=img:2 |
| Rollout | kubectl rollout status|history|undo deploy/web |
| Expose | kubectl expose deploy web --port=80 |
| Debug access | kubectl port-forward svc/web 8080:80, kubectl auth can-i list pods |
| Node maintenance | kubectl cordon|drain|uncordon node |
| Resource usage | kubectl top pods|nodes |
Cheat Sheet: Terraform and Ansible
| Task | Command |
| Terraform workflow | terraform init, fmt, validate, plan -out=tfplan, apply tfplan, destroy |
| State | terraform state list|show|mv|rm, terraform import |
| Drift | terraform plan -refresh-only |
| Console | terraform console |
| Ansible ping | ansible all -i inv -m ping |
| Run playbook | ansible-playbook -i inv site.yml --check --diff, --limit host, --tags x |
| Vault | ansible-vault create|edit|encrypt_string |
| Docs | ansible-doc ansible.builtin.copy |
Which Tool for Which Job?
| Need | Tool |
| Source control and review | Git, GitHub, GitLab |
| Package apps | Docker, Buildpacks |
| Run containers at scale | Kubernetes (EKS, AKS, GKE), ECS |
| CI/CD | GitHub Actions, GitLab CI, Jenkins, Azure Pipelines, CodePipeline |
| Provision infrastructure | Terraform or OpenTofu, CloudFormation, Bicep, Pulumi |
| Configure servers | Ansible, cloud-init, Packer for images |
| Deploy to Kubernetes | Helm, Kustomize, Argo CD, Flux |
| Safe releases | Argo Rollouts, Flagger, feature flags |
| Metrics and alerts | Prometheus, Grafana, Alertmanager, CloudWatch |
| Logs and traces | Loki, ELK/OpenSearch, OpenTelemetry, Tempo, Jaeger |
| Security | Trivy, Semgrep, Gitleaks, cosign, Kyverno, Falco, Vault |
| Developer platform | Backstage, Crossplane |
Common Mistakes To Avoid
- Leaving clusters, NAT gateways, load balancers and databases running after labs
- Hard-coding secrets or committing state files and kubeconfigs
- Using
latest image tags and no resource limits
- Skipping health checks, so bad releases look healthy
- Treating Terraform state as an afterthought (no remote backend or locking)
- Alerting on everything and ignoring pages (alert fatigue)
- Giving CI and applications admin permissions
- Making manual changes in production that code does not describe
- Learning tools without building a project to connect them
Learning Roadmap
| Stage | Learn | Outcome |
| 1. Foundations | Linux, Bash, networking, YAML/JSON, one programming language (Python or Go) | Comfortable in a terminal and scripts |
| 2. Version control | Git, GitHub or GitLab, branching, pull requests | Team workflow |
| 3. Containers | Docker, Compose, registries, image security | Package any app |
| 4. CI/CD | GitHub Actions or GitLab CI, Jenkins basics, testing and artifacts | Automated pipeline |
| 5. Cloud and IaC | AWS or Azure fundamentals, Terraform, Ansible, Packer | Infrastructure from code |
| 6. Kubernetes | Workloads, networking, storage, Helm, RBAC, troubleshooting | Run production workloads |
| 7. Observability and reliability | Prometheus, Grafana, logs, tracing, SLOs, incident response | Know and improve production |
| 8. Security and platform | DevSecOps, GitOps, policy as code, progressive delivery, platform engineering | Senior-level skills |
Certification Path
Always verify: Exam names, versions, prices, durations and prerequisites change. Use each vendor's official page for the current details before you book.
| Certification | Best for | Format and notes |
| Terraform Associate (004) | Infrastructure as code basics, a good first IaC credential | About one hour, multiple choice, online proctored. Tests Terraform concepts and HCP Terraform |
| CKA (Certified Kubernetes Administrator) | Operate and troubleshoot clusters | Hands-on, time-limited lab exam in a terminal. You may use the official docs |
| CKAD | Build and deploy apps on Kubernetes | Hands-on lab exam focused on workloads, config, services and observability |
| CKS | Kubernetes security specialization | Hands-on. Requires active CKA |
| AWS Certified DevOps Engineer - Professional (DOP-C02) | AWS CI/CD, IaC, monitoring, resilience, security automation | Scenario-based multiple choice. Experience with AWS strongly recommended |
| Microsoft Certified: DevOps Engineer Expert (AZ-400) | Azure DevOps, GitHub, pipelines, IaC, monitoring | Scenario-based. Check Microsoft Learn for prerequisites |
| Google Professional Cloud DevOps Engineer | SRE and delivery on Google Cloud | Scenario-based multiple choice |
| Cloud foundations (AWS Cloud Practitioner, AZ-900, Associate level exams) | Starting point before the professional certifications | Cheaper and shorter |
Suggested Order
- Foundations: Linux, Git, Docker (no exam needed, but do the labs)
- Terraform Associate and one cloud associate certification (AWS Solutions Architect Associate, AZ-104 or similar)
- CKA, then CKAD or CKS depending on your role
- A professional DevOps certification for your main cloud (DOP-C02 or AZ-400)
- Keep building projects, because employers value demonstrated skill as much as certificates
Exam Preparation Tips
- Read the official exam guide and map every objective to a lab you did yourself
- For hands-on exams (CKA, CKAD, CKS) practice speed: aliases,
--dry-run=client -o yaml, kubectl explain, searching the allowed documentation, and managing time by skipping hard questions first
- For scenario exams (AWS, Azure) practice choosing the option that is the most automated, secure, scalable and least operational effort
- Take timed practice exams and review every wrong answer by topic
- Use official labs and free tiers. Do not rely only on dumps. They are against exam rules and teach nothing
- Schedule the exam to create a deadline, and plan renewal (most certifications expire after 2 to 3 years)
Resume and Portfolio Ideas
- Show three projects with a README, architecture diagram and a link to the repository: CI/CD to Kubernetes, three-tier AWS with Terraform and Ansible, and the GitOps observability platform
- Use measurable bullets: reduced deployment time from 2 hours to 10 minutes, cut cloud cost by 30 percent, achieved 99.9 percent availability
- List tools by category, and be honest about your depth
- Write short blog posts about problems you solved, and contribute to open source documentation or issues
- Prepare 3 stories (incident, improvement, conflict or learning) for behavioral questions
Career Paths
| Role | Focus |
| DevOps Engineer | Pipelines, infrastructure as code, containers, cloud automation |
| Site Reliability Engineer (SRE) | SLOs, incident response, automation, capacity, reliability engineering |
| Platform Engineer | Internal developer platform, golden paths, Kubernetes and tooling as a product |
| Cloud Engineer / Architect | Cloud design, networking, security, cost, migrations |
| DevSecOps / Security Engineer | Pipeline security, supply chain, compliance, cloud security |
| Release / Build Engineer | Build systems, versioning, release management |
Conclusion
Practice the twelve labs, keep the cheat sheets close, follow the eight-stage roadmap, choose certifications that match your role (Terraform, CKA and a cloud DevOps professional exam are a strong combination), and prove your skills with three well-documented projects.
Quick Summary: 12 labs; cheat sheets; roadmap; Terraform Associate + CKA + cloud DevOps cert; verify exam details; build and document projects.