devops ppt

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 28

DevOps

Bootcamp
Day 1

• What is Devops ?
• Lifecycle of Devops
• Understanding Linux
• Hands on Linux using AWS EC2 instances
Day 2

• What is Git and Github ?


• How Git helps to collaborate !
• Install Git and setup account on Github
• Making your first commit
• First step to full scale Devops Project
Day 3

• What are micro services ?


• Introduction to Containers
• Working with Docker
• Install and setup Docker
• Running containers with Docker
Day 4

• Understanding CI/CD
• How CI/CD helps with deployment
• What is Jenkins ?
• Install and setup Jenkins
• Create your first pipeline
Day 5

• What is the project and end goal


• Understand how different tools help with our goal
• Working with Jenkins and Docker for CI/CD
• Project in action !
• Q/A
What is Devops ?

DevOps is a set of practices, tools, and a cultural philosophy that


automate and integrate the processes between software
development and IT teams. It emphasizes team empowerment,
cross-team communication and collaboration, and technology
automation.
Lifecycle of Devops
Understanding Linux

Linux is a free, open-source and one of the most popular


operating systems in the world, powering everything from mobile
devices and desktops to servers and supercomputers. The Linux
architecture is a modular architecture thatq acts as the backbone
of the Linux operating system and allows its users to customize
and configure the system to meet their specific needs.
Hands on with AWS EC2 instances

• Setup free account on AWS


• Launch Amazon Linux based OS EC2 instances
• Connect to EC2 instance using EC2 instance connect
• Run commands over EC2 instance to interact with it via command
line
Introduction to Containers
• Containers are lightweight, portable, and self-sufficient units that package an application and its
dependencies together.

• Unlike virtual machines (VMs), containers share the host OS kernel, making them more efficient.

• Docker is a platform that simplifies the creation, deployment, and running of containers.

• It allows developers to package applications with all their dependencies into a single container
image.

• Docker enables DevOps teams to build, ship, and run applications consistently across different
environments.
Why Containers in DevOps?

• Portability: Containers work consistently across development, testing, and


production environments.

• Scalability: Containers are lightweight and can be rapidly deployed or destroyed.

• Consistency: Developers can ensure the same application setup and environment
from local machines to production.

• CI/CD: Containers work seamlessly with Continuous Integration and Continuous


Deployment pipelines, improving automation and reducing errors.
Installation for Docker
• sudo apt update
• sudo apt install docker.io –y
• sudo snap install docker
• sudo systemctl status docker
• docker --version
Docker Architecture and
Components
Practical Docker Usage
• docker pull — Download a Docker image from a registry (e.g., docker pull
ubuntu).
• docker images — List available images.
• docker run — Start a new container from an image (e.g., docker run -it
ubuntu bash).
• docker ps — List running containers.
• docker stop <container_id> — Stop a container.
• docker rm <container_id> — Remove a container.
• docker rmi <image_id> — Remove an image.
Docker file
Introduction to CI/CD

• Continuous Integration (CI): Developers frequently integrate their


code changes into a shared repository, where automated builds and
tests are run to detect integration issues early.
• Continuous Delivery (CD): Ensures that the code is always in a
deployable state, and software updates can be released at any time.
This includes automated testing and staging before production
deployment.
• Continuous Deployment (CD): Similar to Continuous Delivery, but
here the code is automatically deployed to production after passing
all tests.
Benefits of CI/CD

• Faster development cycles


• Early detection of bugs
• Reduced manual errors
• More frequent releases and updates
• Improved collaboration and transparency
CI/CD Pipeline Stages
Overview of Jenkins

• Jenkins is an open-source automation server used to set up CI/CD pipelines. It


provides hundreds of plugins to integrate with various tools in the software
development lifecycle.
• Pipeline as Code: Jenkins uses Jenkinsfiles (written in Groovy or Declarative
Pipeline syntax) to define the CI/CD pipeline.
• Wide Plugin Ecosystem: Integrates with tools like Git, Maven, Docker,
Kubernetes, etc.
• Distributed Builds: Jenkins can distribute the build process across multiple
machines.
• Monitoring and Reporting: Provides real-time feedback on the status of
builds and tests
Jenkins Workflow

• Developer commits code to version control.


• Jenkins detects the change via a webhook or polling.
• Jenkins triggers a build process.
• Jenkins runs tests (unit tests, integration tests, etc.).
• Jenkins deploys the code to staging or production (if configured for
CD).
Introduction Git and Github

• What is Git ?
• Distributed Version Control System
• Track changes in file and enable collaboration
• What is Github ?
• A cloud based hosting for Git Repository
• Provides collaboration tools
Installing Git and account creation on Github

• sudo apt install # Ubunutu and Debian


• brew install git #Macos
• git config —global user.name “Your Name”
• git config –global.email “Github email”
Making your first commit

• Git clone <repo-link>


• Git add .
• Git commit –m “commit message”
• Git push origin –m main
Deploy application as
container using CI/CD
Pre-requisites

• EC2 instance
• Jenkins
• Docker
• Git
Structuring of Jenkins Pipeline
Github Repository Overview

• Dockerfile – To create an image for application code


• Jenkinsfile – Pipeline code from SCM
• Webserver files

You might also like