Home
About Us
Contact Us
Bookmark
Saved Bookmarks
Current Affairs
General Knowledge
Chemical Engineering
UPSEE
BSNL
ISRO
BITSAT
Amazon
ORACLE
Verbal Ability
→
Devops
→
DevOps Culture in Devops
→
How do you implement CI/CD using Jenkins?
1.
How do you implement CI/CD using Jenkins?
Answer»
Continuous Integration using Jenkins and Git plugin
Create a new Jenkins item as a ‘Pipeline’.
Add ‘Git’ as
BRANCH
source and give the Project repository url.
Every time source code is pushed to the remote git repository from the local git repo;
Jenkins job gets started(triggered).
Jenkins build the code and the output is available under “
CONSOLE
output”
In the git repository add a ‘jenkinsfile’
COMMIT
and push the code to git repository.
Add a Jenkinsfile in the git repository
pipeline {
AGENT
{ docker { image 'ubuntu:latest' } } stages { stage('build') {
STEPS
{ sh 'uname -a' } } stage('Test') { steps { sh './jenkins/scripts/test.sh' } } } }
Show Answer
Discussion
No Comment Found
Post Comment
Related InterviewSolutions
How to backup and restore Jenkins data and configurations
How does Jenkins handle a failed test case?
How can Jenkins facilitate Deployment in a DevOps practice?
How is Jenkins workspace data shared between different jobs?
Write a sample module to install LAMP on an existing Ubuntu Server Docker image.
What are resources? How do you handle system resources in Puppet?
When joining a new node to the swarm the following error occurs: “Error response from daemon: Timeout was reached before node joined.” How will you fix this?
Explain Docker Orchestration
How do you prune data in a Docker?
Develop your own custom test environment and publish it on the docker hub.
Reply to Comment
×
Name
*
Email
*
Comment
*
Submit Reply
Your experience on this site will be improved by allowing cookies. Read
Cookie Policy
Reject
Allow cookies