{"id":1553,"date":"2026-07-13T18:31:58","date_gmt":"2026-07-13T11:31:58","guid":{"rendered":"https:\/\/sumberlaba.com\/index.php\/2026\/07\/13\/docker-explained-what-it-is-and-how-to-get-started-using-containers\/"},"modified":"2026-07-13T18:31:59","modified_gmt":"2026-07-13T11:31:59","slug":"docker-explained-what-it-is-and-how-to-get-started-using-containers","status":"publish","type":"post","link":"https:\/\/sumberlaba.com\/index.php\/2026\/07\/13\/docker-explained-what-it-is-and-how-to-get-started-using-containers\/","title":{"rendered":"Docker Explained: What It Is and How to Get Started Using Containers"},"content":{"rendered":"<h1>Docker Explained: What It Is and How to Get Started Using Containers<\/h1>\n<p>Docker is a platform that packages applications and their dependencies into lightweight, portable containers. Unlike virtual machines, containers share the host OS kernel, making them faster, smaller, and more efficient. This guide covers the basics and shows you how to run your first container.<\/p>\n<p>Think of a container as a standardized unit of software. It includes everything your app needs: code, runtime, system tools, libraries, and settings. Docker ensures your application runs consistently across different environments\u2014from your laptop to production servers.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/sumberlaba.com\/wp-content\/uploads\/2026\/07\/article-1783942315715.jpg\" alt=\"Article illustration\" style=\"display:block;margin:20px auto;max-width:100%;height:auto;border-radius:8px;\" \/><\/p>\n<h2>Installing Docker<\/h2>\n<p>Download Docker Desktop for Windows, macOS, or Linux from the <a href=\"https:\/\/www.docker.com\/products\/docker-desktop\">official site<\/a>. Follow the installer, and once installed, open a terminal and verify with:<\/p>\n<pre><code>docker --version<\/code><\/pre>\n<h2>Running Your First Container<\/h2>\n<p>Pull an image from Docker Hub, a public registry of pre\u2011built containers. For example, the official Nginx web server:<\/p>\n<pre><code>docker pull nginx<\/code><\/pre>\n<p>Then run it in detached mode, mapping port 80 inside the container to port 8080 on your host:<\/p>\n<pre><code>docker run -d -p 8080:80 nginx<\/code><\/pre>\n<p>Open <code>http:\/\/localhost:8080<\/code> in your browser\u2014you should see the Nginx welcome page.<\/p>\n<h3>Key Docker Commands<\/h3>\n<ul>\n<li><code>docker ps<\/code> \ufffd\ufffd list running containers<\/li>\n<li><code>docker stop &lt;container-id&gt;<\/code> \u2013 stop a container<\/li>\n<li><code>docker images<\/code> \u2013 list downloaded images<\/li>\n<li><code>docker rmi &lt;image-name&gt;<\/code> \u2013 remove an image<\/li>\n<\/ul>\n<h2>Creating a Simple Dockerfile<\/h2>\n<p>A Dockerfile defines how to build your own image. Create a file named <code>Dockerfile<\/code> (no extension):<\/p>\n<pre><code># Use an official Python runtime as base\nFROM python:3.10-slim\n\n# Set the working directory inside the container\nWORKDIR \/app\n\n# Copy the current directory contents into the container\nCOPY . .\n\n# Install dependencies if any (example: Flask)\nRUN pip install flask\n\n# Run app.py when the container launches\nCMD [\"python\", \"app.py\"]<\/code><\/pre>\n<p>Build the image with:<\/p>\n<pre><code>docker build -t my-python-app .<\/code><\/pre>\n<p>Then run it:<\/p>\n<pre><code>docker run -p 5000:5000 my-python-app<\/code><\/pre>\n<h2>Conclusion<\/h2>\n<p>Docker simplifies development and deployment by eliminating &#8220;it works on my machine&#8221; issues. Start with basic commands, explore Docker Hub for ready\u2011to\u2011use images, and gradually build your own containers. Master these fundamentals to unlock the full power of containerization.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Docker Explained: What It Is and How to Get Started Using Containers Docker is a platform that packages applications and their dependencies into lightweight, portable containers. Unlike virtual machines, containers share the host OS kernel, making them faster, smaller, and more efficient. This guide covers the basics and shows you how to run your first &hellip; <\/p>\n","protected":false},"author":2716,"featured_media":1552,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-1553","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-non-category"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/posts\/1553","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/users\/2716"}],"replies":[{"embeddable":true,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/comments?post=1553"}],"version-history":[{"count":1,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/posts\/1553\/revisions"}],"predecessor-version":[{"id":1554,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/posts\/1553\/revisions\/1554"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/media\/1552"}],"wp:attachment":[{"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/media?parent=1553"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/categories?post=1553"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sumberlaba.com\/index.php\/wp-json\/wp\/v2\/tags?post=1553"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}