DevOps Cheat Sheets
Quick reference guides for the most commonly used DevOps tools and commands. Expand any card to view the complete command reference with copy-to-clipboard functionality.
Docker Commands
Essential Docker commands for containerization, image management, and container orchestration.
Show CommandsHide Commands
Image Management
docker pull <image>Download an image from Docker Hub
docker imagesList all local images
docker build -t <name> .Build an image from Dockerfile
docker push <image>Push an image to Docker Hub
docker rmi <image>Remove an image
Container Operations
docker run -d --name <name> <image>Run container in detached mode
docker psList running containers
docker ps -aList all containers
docker stop <container>Stop a running container
docker rm <container>Remove a container
docker exec -it <container> bashOpen shell in running container
docker logs <container>View container logs
Docker Compose
docker-compose up -dStart services in background
docker-compose downStop and remove containers
docker-compose logs -fFollow logs of all services
docker-compose buildRebuild all services
Kubernetes Essentials
Key kubectl commands, resource definitions, and cluster management operations.
Show CommandsHide Commands
Cluster Info
kubectl cluster-infoDisplay cluster information
kubectl get nodesList all nodes in the cluster
kubectl get namespacesList all namespaces
kubectl config get-contextsList available contexts
Pod Management
kubectl get podsList pods in current namespace
kubectl get pods -AList pods in all namespaces
kubectl describe pod <pod>Show details of a pod
kubectl logs <pod>Print container logs
kubectl exec -it <pod> -- bashExecute command in pod
kubectl delete pod <pod>Delete a pod
Deployments & Services
kubectl get deploymentsList all deployments
kubectl get servicesList all services
kubectl apply -f <file>.yamlApply a configuration file
kubectl scale deployment <name> --replicas=3Scale a deployment
kubectl rollout status deployment/<name>Check rollout status
Git Commands
Complete Git reference including branching, merging, rebasing, and advanced operations.
Show CommandsHide Commands
Basic Commands
git initInitialize a new Git repository
git clone <url>Clone a repository
git statusCheck working directory status
git add .Stage all changes
git commit -m "<message>"Commit staged changes
git push origin <branch>Push to remote repository
git pull origin <branch>Pull from remote repository
Branching
git branchList branches
git branch <name>Create a new branch
git checkout <branch>Switch to a branch
git checkout -b <branch>Create and switch to new branch
git merge <branch>Merge branch into current branch
git branch -d <branch>Delete a branch
Advanced
git rebase <branch>Rebase current branch
git stashStash current changes
git stash popApply stashed changes
git reset --hard HEAD~1Reset to previous commit
git log --onelineView commit history (compact)
Linux Commands
Essential Linux commands for system administration, file management, and networking.
Show CommandsHide Commands
File Operations
ls -laList files with details
cd <directory>Change directory
pwdPrint working directory
cp <src> <dest>Copy files
mv <src> <dest>Move or rename files
rm -rf <path>Remove files/directories
mkdir -p <path>Create nested directories
System Info
topDisplay running processes
df -hShow disk usage
free -hDisplay memory usage
uname -aShow system information
ps auxList all processes
Networking
curl <url>Make HTTP request
netstat -tulnShow listening ports
ping <host>Test network connectivity
ssh user@hostSSH into remote server
scp <file> user@host:<path>Secure copy to remote
Terraform Syntax
HCL syntax reference, resource configurations, and state management commands.
Show CommandsHide Commands
Core Commands
terraform initInitialize working directory
terraform planPreview changes
terraform applyApply changes
terraform destroyDestroy infrastructure
terraform validateValidate configuration
terraform fmtFormat configuration files
State Management
terraform state listList resources in state
terraform state show <resource>Show resource details
terraform state rm <resource>Remove resource from state
terraform import <addr> <id>Import existing resource
terraform refreshUpdate state with real infrastructure
Workspaces
terraform workspace listList workspaces
terraform workspace new <name>Create new workspace
terraform workspace select <name>Switch workspace
terraform workspace delete <name>Delete a workspace
AWS CLI Reference
Common AWS CLI commands for EC2, S3, IAM, and other essential services.
Show CommandsHide Commands
EC2
aws ec2 describe-instancesList EC2 instances
aws ec2 start-instances --instance-ids <id>Start an instance
aws ec2 stop-instances --instance-ids <id>Stop an instance
aws ec2 terminate-instances --instance-ids <id>Terminate an instance
aws ec2 describe-security-groupsList security groups
S3
aws s3 lsList S3 buckets
aws s3 ls s3://<bucket>List bucket contents
aws s3 cp <file> s3://<bucket>/Upload file to S3
aws s3 sync <dir> s3://<bucket>/Sync directory to S3
aws s3 rm s3://<bucket>/<key>Delete S3 object
IAM
aws iam list-usersList IAM users
aws iam list-rolesList IAM roles
aws iam get-userGet current user details
aws sts get-caller-identityGet current identity