diff --git a/2025/docker/task1_sol.md b/2025/docker/task1_sol.md new file mode 100644 index 000000000..41a44f1d9 --- /dev/null +++ b/2025/docker/task1_sol.md @@ -0,0 +1,18 @@ +### Task 1: Introduction and Conceptual Understanding +1. **Write an Introduction:** + - In your `solution.md`, provide a brief explanation of Docker’s purpose in modern DevOps. + - Compare **Virtualization vs. Containerization** and explain why containerization is the preferred approach for microservices and CI/CD pipelines. + + +### Introduction to Docker + +Docker is an OS‑level virtualization (or containerization) platform, which allows applications to share the host OS kernel instead of running a separate guest OS like in traditional virtualization. This design makes Docker containers lightweight, fast, and portable, while keeping them isolated from one another. + +** Containers vs. virtualization ** +Containers are an abstraction that packages application code and dependencies together. Instances of the container can then be created, started, stopped, moved, or deleted using the Docker API or command-line interface (CLI). Containers can be connected to one or more networks, be attached to storage, or create new images based on their current states. + +Containers differ from virtual machines, which use a software abstraction layer on top of computer hardware, allowing the hardware to be shared more efficiently in multiple instances that will run individual applications. Docker containers require fewer physical hardware resources than virtual machines, and they also offer faster startup times and lower overhead. This makes Docker ideal for high-velocity environments, where rapid software development cycles and scalability are crucial. + +![alt text](image-1.png) + +Containerization is the preferred approach for microservices and CI/CD pipelines because it offers crucial benefits such as isolation, consistency, and portability. These benefits streamline development, testing, and deployment, making the entire process faster and more reliable. diff --git a/2025/docker/task2/app.py b/2025/docker/task2/app.py new file mode 100644 index 000000000..e4b113573 --- /dev/null +++ b/2025/docker/task2/app.py @@ -0,0 +1,10 @@ +from flask import Flask +app = Flask(__name__) + +@app.route('/') +def hello_world(): + return 'Hello, World!' + +if __name__ == '__main__': + app.run(host='0.0.0.0', port=5000) + diff --git a/2025/docker/task2/image.png b/2025/docker/task2/image.png new file mode 100644 index 000000000..d92517b43 Binary files /dev/null and b/2025/docker/task2/image.png differ diff --git a/2025/docker/task2/requirements.txt b/2025/docker/task2/requirements.txt new file mode 100644 index 000000000..2077213c3 --- /dev/null +++ b/2025/docker/task2/requirements.txt @@ -0,0 +1 @@ +Flask \ No newline at end of file diff --git a/2025/docker/task2/task2_sol.md b/2025/docker/task2/task2_sol.md new file mode 100644 index 000000000..e1313ae01 --- /dev/null +++ b/2025/docker/task2/task2_sol.md @@ -0,0 +1,4 @@ +### Task 2: Create a Dockerfile for a Sample Project +1. **Select or Create a Sample Application:** + - Choose a simple application (for example, a basic Node.js, Python, or Java app that prints “Hello, Docker!” or serves a simple web page). + diff --git a/2025/linux/task1_sol b/2025/linux/task1_sol new file mode 100644 index 000000000..e69de29bb diff --git a/2025/linux/task1_sol.md b/2025/linux/task1_sol.md new file mode 100644 index 000000000..0b2868c34 --- /dev/null +++ b/2025/linux/task1_sol.md @@ -0,0 +1,19 @@ +/* +Task: +Create a user devops_user and add them to a group devops_team. + +# useradd devops_user +# groupadd devops_team +# gpasswd -a devops_user devops_team + +Set a password and grant sudo access. +# sudo passwd devops_user + +Restrict SSH login for certain users in /etc/ssh/sshd_config. +# cd /etc/ssh +# vi sshd_config +# add a keyword AllowAccess +*/ + + + diff --git a/2025/networking/solution b/2025/networking/solution new file mode 100644 index 000000000..e69de29bb