Task Description 📄
👉 Pull the Docker container image of CentOS image from DockerHub and create a new container
👉 Install the Python software on the top of docker container
👉 In Container you need to create machine learning model
Let’s start by asking a Important question!!
What is Docker?
According to wikipedia, Docker is a set of platform as a service products that use OS-level virtualization to deliver software in packages called containers. Containers are isolated from one another and bundle their own software, libraries and configuration files; they can communicate with each other through well-defined channels.
Docker: Top 7 Benefits of Containerization
⚙Consistent and Isolated Environment
⚙Cost-effectiveness with Fast Deployment
⚙Mobility — Ability to Run Anywhere
⚙Repeatability and Automation
⚙Test, Roll Back and Deploy
⚙Flexibility
⚙Collaboration, Modularity and Scaling
✔Step-1 : Add a Docker repo in “/etc/yum.repos.d/” to install Docker-ce
# vim dockerce.repo
# yum install docker-ce — nobest -y
# systemctl enable docker — now

✔Step-2 : Running the Docker Container using Centos Image

✔Step-3 : Copying my Salary_Data.csv which will be needed to train the Model.
# docker cp Salary_Data.csv mlos1:/
>> Here Salary_Data.csv is my file name which I want to Copy to docker Container
>> “mlos1” is the Container Name
>> Inside Docker we are copying file in ‘/’ Directory

✔Step-4 : Installing Required Software to create a ML model
# yum install python3
# pip3 install pandas
# pip3 install scikit-learn

✔Step-5 : Creating a Basic Linear Regression ML
#yum install vim -y
# vim predict.py

✔Step-6: Running the Final Created Code to predict the Salary as per Years

THANK YOU FOR READING!!
To connect: https://www.linkedin.com/in/rishabh-465a85185/
To Check-out the code: https://github.com/Rishbah-76/Basic_Linear_Regression_model/tree/main