0% found this document useful (0 votes)
8 views3 pages

UNIT 4

Download as docx, pdf, or txt
Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1/ 3

Jenkins Build Server;Jenkins is a popular open-source automation server that helps developers automate

parts of the software development process. A Jenkins build server is responsible for building, testing, and
deploying software projects;A Jenkins build server is typically set up on a dedicated machine or a virtual
machine, and is used to manage the continuous integration and continuous delivery (CI/CD) pipeline for a
software project. The build server is configured with all the necessary tools, dependencies, and plugins to
build, test, and deploy the project;The build process in Jenkins typically starts with code being committed to a
version control system (such as Git), which triggers a build on the Jenkins server. The Jenkins server then
checks out the code, builds it, runs tests on it, and if everything is successful, deploys the code to a staging or
production environment;Jenkins has a large community of developers who have created hundreds of plugins
that extend its functionality, so it's easy to find plugins to support specific tools, technologies, and workflows.
For example, there are plugins for integrating with cloud infrastructure, running security scans, deploying to
various platforms, and more;Overall, a Jenkins build server can greatly improve the efficiency and reliability of
the software development process by automating repetitive tasks, reducing the risk of manual errors, and
enabling developers to focus on writing code.

Jenkins Plugins;are packages of software that extend the functionality of the Jenkins automation server.
Plugins allow you to integrate Jenkins with various tools, technologies, and workflows, and can be easily
installed and configured through the Jenkins web interface;Some popular Jenkins plugins include;Git Plugin;
This plugin integrates Jenkins with Git version control system, allowing you to pull code changes, build and test
them, and deploy the code to production;Maven Plugin;This plugin integrates Jenkins with Apache Maven, a
build automation tool commonly used in Java projects;Amazon Web Services (AWS) Plugin;This plugin allows
you to integrate Jenkins with Amazon Web Services (AWS), making it easier to run builds, tests, and
deployments on AWS infrastructure;Slack Plugin;This plugin integrates Jenkins with Slack, allowing you to
receive notifications about build status, failures, and other important events in your Slack channels;Blue
Ocean Plugin;This plugin provides a new and modern user interface for Jenkins, making it easier to use and
navigate;Pipeline Plugin;This plugin provides a simple way to define and manage complex CI/CD pipelines in
Jenkins;Jenkins plugins are easy to install and can be managed through the Jenkins web interface. There are
hundreds of plugins available, covering a wide range of tools, technologies, and use cases, so you can easily
find the plugins that best meet your needs.

Managing build dependencies;is an important aspect of continuous integration and continuous delivery
(CI/CD) pipelines. In software development, dependencies refer to external libraries, tools, or resources that a
project relies on to build, test, and deploy. Proper management of dependencies can ensure that builds are
repeatable and that the build environment is consistent and up-to-date;Dependency Management
Tools;Utilize tools such as Maven, Gradle, or npm to manage dependencies and automate the process of
downloading and installing required dependencies for a build;Version Pinning;Specify exact versions of
dependencies to ensure builds are consistent and repeatable;Caching;Cache dependencies locally on the build
server to improve build performance and reduce the time it takes to download dependencies;Continuous
Monitoring;Regularly check for updates and security vulnerabilities in dependencies to ensure the build
environment is secure and up-to-date;Automated Testing;Automated testing can catch issues related to
dependencies early in the development process;By following these practices, you can effectively manage build
dependencies and maintain the reliability and consistency of your CI/CD pipeline.
Trigger;A trigger is like a start button that begins an action automatically based on certain conditions or
events;Trigger builds remotely;If you want to trigger your project built from anywhere anytime then you
should selectTrigger builds remotely option from the build triggers;You’ll need to provide an authorization
token in the form of a string so that only those who know it would be able to remotely trigger this project’s
builds. This provides the predefined URL to invoke this trigger remotely;Build after other projects are built;If
your project depends on another project build then you should select Build after other projects are
built option from the build triggers; In this, you must specify the project(Job) names in the Projects to
watch field section and select one of the following options;Trigger only if the build is stable;Trigger even if the
build is unstable;Trigger even if the build fails; After that, It starts watching the specified projects in
the Projects to watch section;Build periodically; If ou want to schedule your project build periodically then
you should select the Build periodically option from the build triggers;You must specify the periodical duration
of the project build in the scheduler field section;This field follows the syntax of cron (with minor differences).
Specifically, each line consists of 5 fields separated by TAB or whitespace; To specify multiple values for one
field, the following operators are available. In the order of precedence;* specifies all valid values;M-N specifies
a range of values;M-N/X or */X steps by intervals of X through the specified range or whole valid range;
A,B,...,Z enumerates multiple values;GitHub webhook trigger for GITScm polling;A webhook is an HTTP
callback, an HTTP POST that occurs when something happens through a simple event-notification via HTTP
POST;GitHub webhooks in Jenkins are used to trigger the build whenever a developer commits something to
the branch; Poll SCM;periodically polls the SCM to check whether changes were made (i.e. new commits) and
builds the project if new commits were pushed since the last build;You must schedule the polling duration in
the scheduler field. Like we explained above in the Build periodically section. You can see the Build periodically
section to know how to schedule;After successfully scheduled, the scheduler polls the SCM according to your
specified duration in scheduler field and builds the project if new commits were pushed since the last
build.LET'S INITIATE A PARTNERSHIP

Job Chaining;in Jenkins refers to the process of linking multiple build jobs together in a sequence. When one
job completes, the next job in the sequence is automatically triggered;There are several ways;Build Trigger;
You can use the build trigger in Jenkins to start one job after another. This is done by configuring the upstream
job to trigger the downstream job when it completes;Jenkinsfile;If you are using Jenkins Pipeline, you can
write a Jenkinsfile to define the steps in your build pipeline. The Jenkinsfile can contain multiple stages, each
of which represents a separate build job in the pipeline;JobDSL plugin;The JobDSL plugin allows you to
programmatically create and manage Jenkins jobs. You can use this plugin to create a series of jobs that are
linked together and run in sequence;Multi-Job plugin;The Multi-Job plugin allows you to create a single job
that runs multiple build steps, each of which can be a separate build job. This plugin is useful if you have a
build pipeline that requires multiple build jobs to be run in parallel;By chaining jobs in Jenkins, you can
automate the entire build process and ensure that each step is completed before the next step is started.

Build Pipeline;in DevOps is a set of automated processes that compile, build, and test software, and prepare it
for deployment;Steps;Code Commit;Developers commit code changes to a version control system such as Git.
;Build and Compile;The code is built and compiled,and any necessary dependencies are resolved;Unit Testing;
Automated unit tests are run to validate the code changes;Integration Testing;Automated integration tests
are run to validate that the code integrates correctly with other parts of the system;Staging;The code is
deployed to a staging environment for further testing and validation;Release;If the code passes all tests, it is
deployed to the production environment;Monitoring;The deployed code is monitored for performance and
stability;A build pipeline can be managed using a continuous integration tool such as Jenkins, TravisCI, or
CircleCI. These tools automate the build process, allowing you to quickly and easily make changes to the
pipeline, and ensuring that the pipeline is consistent and reliable.
Build servers;When you're developing and deploying software, one of the first things to figure out is how to
take your code and deploy your working application to a production environment where people can interact
with your software;Steps;Requirements gathering;Determine the requirements for the server, such as
hardware specifications, operating system, and software components needed;Server provisioning;Choose a
method for provisioning the server, such as physical installation, virtualization, or cloud computing;Operating
System installation;Install the chosen operating system on the server;Software configuration;Install and
configure the necessary software components, such as web servers, databases, and middleware;Network
configuration;Set up network connectivity, such as IP addresses, hostnames, and firewall rules;Security
configuration;Configure security measures, such as user authentication, access control, and encryption;
Monitoring and maintenance;Implement monitoring and maintenance processes, such as logging, backup,
and disaster recovery;Deployment;Deploy the application to the server and test it to ensure it is functioning
as expected;Throughout the process, it is important to automate as much as possible using tools such as
Ansible, Chef, or Puppet to ensure consistency and efficiency in building servers.

Infrastructure as code (IAC);uses DevOps methodology and versioning with a descriptive model to define and
deploy infrastructure, such as networks, virtual machines, load balancers, and connection topologies. Just as
the same source code always generates the same binary, an IaC model generates the same environment every
time it deploys;Benefits of IAC include;Speed;IAC enables quick and efficient provisioning and deployment of
infrastructure;Consistency;By using code to define and manage infrastructure, it is easier to ensure
consistency across multiple environments;Repeatability;IAC allows for easy replication of infrastructure
components in different environments, such as development, testing, and production;Scalability;IAC makes it
easier to scale infrastructure as needed by simply modifying the code;Version control;Infrastructure
components can be versioned, allowing for rollback to previous versions if necessary;Overall, IAC is a key
component of modern DevOps practices, enabling organizations to manage their infrastructure in a more
efficient, reliable, and scalable way.

Alternative build servers; There are several alternative build servers in DevOps, including;Jenkins;an open-
source, Java-based automation server that supports various plugins and integrations;Travis CI;a cloud-based,
open-source CI/CD platform that integrates with Github;CircleCI;a cloud-based, continuous integration and
delivery platform that supports multiple languages and integrates with several platforms;GitLab CI/CD;an
integrated CI/CD solution within GitLab that allows for complete project and pipeline management;Bitbucket
Pipelines;a CI/CD solution within Bitbucket that allows for pipeline creation and management within the code
repository;AWS CodeBuild;a fully managed build service that compiles source code, runs tests, and produces
software packages that are ready to deploy;Azure Pipelines;a CI/CD solution within Microsoft Azure that
supports multiple platforms and programming languages.

Collating Quality;measures is an important part of the continuous improvement process. The following are
some common quality measures used in DevOps to evaluate the quality of software systems;Continuous
Integration (CI) metrics;metrics that track the success rate of automated builds and tests, such as build
duration and test pass rate;Continuous Deployment (CD) metrics;metrics that track the success rate of
deployments, such as deployment frequency and time to deployment;Code review metrics;metrics that track
the effectiveness of code reviews, such as review completion time and code review feedback;Performance
metrics;measures of system performance in production, such as response time and resource utilization;User
experience metrics;measures of how users interact with the system, such as click-through rate and error rate
;Security metrics;measures of the security of the system, such as the number of security vulnerabilities and
the frequency of security updates;Incident response metrics; metrics that track the effectiveness of incident
response, such as mean time to resolution (MTTR) and incident frequency;By regularly collating these quality
measures, DevOps teams can identify areas for improvement, track progress over time, and make informed
decisions about the quality of their systems.

You might also like