Pankil Soni Profile Picture

Pankil Soni

AI Engineer / Full-Stack Engineer

Gujarat, India

Let's TalkLet's Talk
All Articles
Getting Started with Docker 🐳

Oct 22, 2024

Getting Started with Docker 🐳

Today marks the beginning of my DevOps learning journey, and I kicked it off by diving into Docker. Here's what I learned and accomplished on my first day.

no more it works on my machine πŸš€

Understanding the Basics

First, I grasped the fundamental concepts:

  • Containers: Lightweight, standalone packages that include everything needed to run a piece of software, ensuring consistency across different environments.

  • Docker: A platform that enables creating, deploying, and running applications using container technology.

  • Docker Hub: The official repository for Docker images, like GitHub but for container images.

Essential Docker Commands

I learned several basic Docker commands that are crucial for container management:

List all running containers

docker ps

List all Docker images on your system

docker image ls

Pull an image from Docker Hub

docker pull [image-name]

Remove containers or images

docker rm [container-id/name]

Run a container

docker run [options] [image-name]

Hands-on Practice: Running Nginx

My first practical exercise was setting up an Nginx web server using Docker. Here's how I did it:

docker pull nginx
docker run --name my-nginx -p 8080:80 -d nginx

Let's break down this command:

  • --name my-nginx: Assigns a custom name to the container

  • -p 8080:80: Maps port 8080 on my host to port 80 in the container

  • -d: Runs the container in detached mode (background)

  • nginx: The image to use

Connecting to Docker Playground

One interesting challenge I tackled was accessing Docker Playground from Windows using Git Bash via SSH. This gave me experience with:

  • Remote container management

  • Using SSH for remote connections

https://stackoverflow.com/a/79113715/24263125 refer to my this comment to ssh docker playground instance.

Key Takeaways from Day 1

  1. Docker simplifies application deployment through containerization

  2. Basic Docker commands are intuitive and follow a logical pattern

  3. Port mapping is crucial for accessing containerized applications

  4. Docker Playground provides a great environment for learning

What's Next?

Tomorrow, I plan to explore:

  • Create own docker image using as Dockerfile.

  • Deploying own simple express app.

  • Multi-container applications.

  • Docker networking basics.

the resource I used for learning docker is : https://youtu.be/rr9cI4u1_88?si=s8ehmucFYWfjcci5

Stay tuned for more updates on my DevOps journey! Feel free to share your thoughts and suggestions in the comments below.

#Docker #DevOps #Learning #TechBlog

More Articles

MCP Servers: Beyond the Hype πŸš€

Jun 29, 2025

MCP Servers: Beyond the Hype πŸš€

My First tech Internship (Remote)

Jul 7, 2024

My First tech Internship (Remote)

Frequently Asked Questions

Let's
Connect

Connect with me on linkedin to Hire me or Contact me to create any projects, get services from me or feel free to connect with me for any reasons.

Made by Pankil Soni with ❀️