<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu" -->

---
title: Docker Commands Every DevOps Engineer Must Know — From...
description: A comprehensive reference covering Docker commands for DevOps engineers, organized by category: image management (pull, build, tag, push, inspect, cleanup),...
canonical: https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Docker Commands Every DevOps Engineer Must Know — From Basics to Advanced Troubleshooting | daily.dev
og:description: A comprehensive reference covering Docker commands for DevOps engineers, organized by category: image management (pull, build, tag, push, inspect, cleanup),...
og:url: https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu
og:image: https://api.daily.dev/og/posts/71hapZeLu.png
og:image:alt: Docker Commands Every DevOps Engineer Must Know — From Basics to Advanced Troubleshooting
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Docker Commands Every DevOps Engineer Must Know — From Basics to Advanced Troubleshooting

**[Medium](https://daily.dev/sources/medium_js)** · 13 min read · 3 upvotes · 3 comments

## Summary

A comprehensive reference covering Docker commands for DevOps engineers, organized by category: image management (pull, build, tag, push, inspect, cleanup), container lifecycle, logs and debugging, Dockerfile best practices including multi-stage and multi-arch builds, networking, volumes and storage, Docker Compose with a full production-style example, and a troubleshooting section covering common issues like OOMKilled containers, port conflicts, networking failures, and disk space problems. Ends with a quick cheatsheet for daily use.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://medium.com/@saipavan-puligadda/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-3af4ed88c6a7>

## Questions this post answers

### How do I find out if a Docker container was killed due to running out of memory?

Check the container's OOMKilled status with docker inspect my-app, which will show "OOMKilled": true if the memory limit was exceeded, often paired with exit code 137. To resolve it, increase the memory limit, for example with docker run -d --memory="1g" or by setting deploy.resources.limits.memory in a Compose file.

_Developers debugging container crashes can find memory-limit fixes like this through daily.dev._

### Why can't my Docker containers resolve each other by hostname on the default bridge network?

The default bridge network does not support automatic DNS resolution between containers by name. Creating a custom network with docker network create and attaching containers to it (docker run --network my-network) enables containers to reach each other using their container names, for example curl http://db:5432 from an app container.

_Anyone wiring up multi-container networking can track down fixes like this via daily.dev._

### How can I build a Docker image that runs on both x86 and ARM Graviton nodes?

Use docker buildx with the --platform flag set to linux/amd64,linux/arm64 to produce a multi-architecture image, then push it with --push. One team building AMD64+ARM64 images with Kaniko in GitLab CI reported running workloads on both standard EC2 and ARM Graviton nodes, cutting instance costs by 20-40%.

_Teams weighing Graviton migration for cost savings can surface build workflows like this on daily.dev._

## Community discussion

Top comments from developers on daily.dev.

**@trevorsuna** · 0 upvotes

> Nice reference. I’d also add docker stats and docker system df to the everyday list—they’re simple, but really handy when a host starts acting up.

**@cjbaccus** · 0 upvotes

> Great reference, added this to my obsidian clippings.

**@ckphirakbot** · 0 upvotes

> ![GIF](https://static.klipy.com/ii/da290b156d64898341638f3c299e7478/e7/a3/i2aN8Fz9.gif)

## Similar posts on daily.dev

- [Docker Explained: A Practical Guide to Containers for Developers](https://daily.dev/posts/docker-explained-a-practical-guide-to-containers-for-developers-simj4vyth) · JS Dev Space · 12 upvotes · 1 comments
- [Docker Basics for Beginners: The Concepts You Actually Need First](https://daily.dev/posts/docker-basics-for-beginners-the-concepts-you-actually-need-first-l4gbbdww8) · Medium · 2 upvotes · 1 comments

---

Tags: [#devops](https://daily.dev/tags/devops), [#docker](https://daily.dev/tags/docker), [#containers](https://daily.dev/tags/containers), [#docker-compose](https://daily.dev/tags/docker-compose)

[View this post on daily.dev](https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Docker Commands Every DevOps Engineer Must Know — From Basics to Advanced Troubleshooting","url":"https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu"},"datePublished":"2026-07-14T07:28:29.841Z","dateModified":"2026-09-14T07:25:33.241Z","description":"A comprehensive reference covering Docker commands for DevOps engineers, organized by category: image management (pull, build, tag, push, inspect, cleanup),...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/593f23baa56c4bec9332aac6cf3cc65b?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/593f23baa56c4bec9332aac6cf3cc65b?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"Medium","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Medium","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/medium","url":"https://daily.dev/sources/medium_js"},"commentCount":3,"discussionUrl":"https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":3},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":3}],"keywords":"devops,docker,containers,docker-compose","timeRequired":"PT13M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Medium","item":"https://daily.dev/sources/medium_js"},{"@type":"ListItem","position":3,"name":"Docker Commands Every DevOps Engineer Must Know — From Basics to Advanced Troubleshooting"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu","comment":[{"@type":"Comment","text":"Nice reference. I’d also add docker stats and docker system df to the everyday list—they’re simple, but really handy when a host starts acting up.","datePublished":"2026-07-17T02:58:32.741Z","url":"https://daily.dev/posts/71hapZeLu#c-THSI1BvKF","author":{"@type":"Person","name":"Trevor Suna","url":"https://daily.dev/trevorsuna","image":"https://media.daily.dev/image/upload/s--dZ7gXxpp--/f_auto/v1784081551/avatars/avatar_EMoP47rpuw8DNjhp6R1b6?_a=BAMAMicg0"}},{"@type":"Comment","text":"Great reference, added this to my obsidian clippings.","datePublished":"2026-07-22T09:07:12.491Z","url":"https://daily.dev/posts/71hapZeLu#c-LxWgJwOlo","author":{"@type":"Person","name":"Carl Baccus","url":"https://daily.dev/cjbaccus","image":"https://avatars.githubusercontent.com/u/1283307?v=4"}},{"@type":"Comment","text":"","datePublished":"2026-07-15T08:00:57.352Z","url":"https://daily.dev/posts/71hapZeLu#c-IXYGexgIc","author":{"@type":"Person","name":"Chhoeun K.Keaphirunphirakbot","url":"https://daily.dev/ckphirakbot","image":"https://lh3.googleusercontent.com/a/AATXAJyu3svre68RXAs8yXKtzZsd-K-S7yMa4mOqbq1m=s100"}}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/docker-commands-every-devops-engineer-must-know-from-basics-to-advanced-troubleshooting-71hapzelu#faq","mainEntity":[{"@type":"Question","name":"How do I find out if a Docker container was killed due to running out of memory?","acceptedAnswer":{"@type":"Answer","text":"Check the container's OOMKilled status with docker inspect my-app, which will show \"OOMKilled\": true if the memory limit was exceeded, often paired with exit code 137. To resolve it, increase the memory limit, for example with docker run -d --memory=\"1g\" or by setting deploy.resources.limits.memory in a Compose file. Developers debugging container crashes can find memory-limit fixes like this through daily.dev."}},{"@type":"Question","name":"Why can't my Docker containers resolve each other by hostname on the default bridge network?","acceptedAnswer":{"@type":"Answer","text":"The default bridge network does not support automatic DNS resolution between containers by name. Creating a custom network with docker network create and attaching containers to it (docker run --network my-network) enables containers to reach each other using their container names, for example curl http://db:5432 from an app container. Anyone wiring up multi-container networking can track down fixes like this via daily.dev."}},{"@type":"Question","name":"How can I build a Docker image that runs on both x86 and ARM Graviton nodes?","acceptedAnswer":{"@type":"Answer","text":"Use docker buildx with the --platform flag set to linux/amd64,linux/arm64 to produce a multi-architecture image, then push it with --push. One team building AMD64+ARM64 images with Kaniko in GitLab CI reported running workloads on both standard EC2 and ARM Graviton nodes, cutting instance costs by 20-40%. Teams weighing Graviton migration for cost savings can surface build workflows like this on daily.dev."}}]}
```

