Docker EXEC Operations

Veröffentlicht am: 17 April 2026
auf dem Kanal: Otter Tech
13
1

🐳 Docker EXEC Operations | Docker Level-2 Series | Lab 4

Welcome to Lab 4 of the Docker Level-2 Series! In this hands-on lab, you’ll learn how to execute commands inside a running container and configure services—an essential skill for real-world container management.

A Nautilus DevOps team member started configuring services inside a running container but had to step away. Your task is to step in, complete the setup, and ensure everything is running properly inside the container.

📌 Lab Objective:
Use Docker exec to configure and manage services داخل a running container.

🛠️ Task Requirements:

Container Name: kkloud
Server: App Server 2
Install apache2 inside the container
Configure Apache to run on port 8087
Ensure Apache service is running
Keep the container in running state

💻 Step-by-Step Commands:

Connect to App Server 2
ssh steve@stapp02
Access the running container
sudo docker exec -it kkloud bash
Update package index and install apache2
apt update
apt install -y apache2
Change Apache port from 80 to 8087
sed -i 's/80/8087/g' /etc/apache2/ports.conf
Update default virtual host config
sed -i 's/:80/:8087/g' /etc/apache2/sites-available/000-default.conf
Start Apache service
service apache2 start
Verify Apache is running
service apache2 status
Exit container
exit
Ensure container is still running
sudo docker ps

✅ Expected Outcome:

Apache installed inside container
Running on port 8087
Service is active and running
Container remains up and running

🌟 Why This Lab Matters:
Being able to access and configure running containers is crucial for debugging, quick fixes, and real-time updates in production environments. This skill is widely used in DevOps and container-based deployments.

🎯 Series: Docker Level-2
Master Docker with real-world labs covering containers, images, networking, and advanced operations.

🔔 Don’t forget to like, share, and subscribe for more tutorials from OtterTech!

#Docker #DevOps #Containers #Apache #DockerExec #Containerization #OpenSource #Nautilus #StratosDatacenter #DockerLevel2 #100DaysOfDevOps #OtterTech #Lab4


Auf dieser Seite können Sie das Online-Video Docker EXEC Operations mit der Dauer stunde minuten sekunde in guter Qualität ansehen, das der Benutzer Otter Tech 17 April 2026 hochgeladen hat, den Link mit Freunden und Bekannten teilen, dieses Video wurde auf Youtube bereits 13 Mal angesehen und es wurde von 1 den Zuschauern gefallen. Viel Spaß beim Betrachtenden Zuschauern gefallen!