How to install Docker and use it ?
- Sharon Rajendra Manmothe

- 17 hours ago
- 2 min read
STEP 1: Install Docker Desktop (Free)
Go to https://www.docker.com/products/docker-desktop/

Click “Download for Windows”.
Run the downloaded file → follow installer steps → keep default settings.
Restart your computer if asked.
Open Docker Desktop → wait till it says “Docker is running”.

Check in Command Prompt:
docker --version

If it shows a version, Docker is ready.
🧱STEP 2: Pull and Run a Container
Now let’s run some ready-made containers.
Open Command Prompt or PowerShell.
Run this:
docker run hello-world
This tests your Docker setup. If you see “Hello from Docker!”, everything works fine.

Run a small web server:
docker run -d -p 8080:80 nginx
-d → run in background
-p 8080:80 → open it on port 8080
Open your browser → go to http://localhost:8080
You’ll see the NGINX welcome page.
STEP 3: Create Your Own Simple Docker App
Let’s make a small Python app and put it in a Docker image.
Step 3.1 — Create folder
Create a folder anywhere, like:
C:\docker-flask-app
Open Notepad, paste the following, and save as app.py inside that folder:
from flask import Flask
app = Flask(__name__)
@app.route('/')
def home():
return "Hello from my first Docker app!"
if __name__ == '__main__':
app.run(host='0.0.0.0', port=5000)
Also create a file named requirements.txt in the same folder:
flask
Now create another file named Dockerfile (no extension):
FROM python:3.10
WORKDIR /app
COPY . /app
RUN pip install -r requirements.txt
EXPOSE 5000
CMD ["python", "app.py"]
Step 3.2 — Build your Docker image
Open Command Prompt inside your folder (Shift + Right Click → “Open PowerShell window here”)
Run:
docker build -t myflaskapp .
Wait for it to finish.
Step 3.3 — Run your container
docker run -d -p 5000:5000 myflaskapp
Now open your browser → visit👉 http://localhost:5000
You’ll see:“Hello from my first Docker app!”
That’s it!
You have done:
Installed Docker
Pulled and ran containers
Created your own custom image

$50
Product Title
Product Details goes here with the simple product description and more information can be seen by clicking the see more button. Product Details goes here with the simple product description and more information can be seen by clicking the see more button

$50
Product Title
Product Details goes here with the simple product description and more information can be seen by clicking the see more button. Product Details goes here with the simple product description and more information can be seen by clicking the see more button.

$50
Product Title
Product Details goes here with the simple product description and more information can be seen by clicking the see more button. Product Details goes here with the simple product description and more information can be seen by clicking the see more button.




Comments