
Develop skills in Jenkins continuous integration and deployment through 70 hands-on tasks, from environment setup and freestyle jobs to declarative pipelines, Docker CD, and plugin management.
Create an AWS free tier account by signing up and verifying your email. Set a root password, link a credit card, complete identity verification, and sign in to the console.
Launch an ec2 instance for Jenkins in us east 1, using amazon linux and t2.micro, with a DevOps key pair and 15 gb storage.
Learn how to sign up for GitLab using your Gmail account or Google login, fill out basic details, accept terms, and access GitLab.
Set up a blank private GitLab project named Jenkins-DevOps, then integrate a Jenkins file and connect GitLab with Jenkins to design multiple pipelines.
Create a Jenkins freestyle job named docker-verify, add a shell build step to run docker --version, and run the job to verify Docker on the Jenkins machine.
Learn to schedule a freestyle Jenkins job using cron by configuring build periodically with a five-field pattern to run every minute, then save and verify via console output.
Turn a Jenkins freestyle job into a parameterized build with a choice parameter named package (Docker or Python) and use $package in the shell to display the selected version.
Temporarily disable the docker verify job in Jenkins to prevent builds via the build now button, then save and re-enable it when needed.
Create a declarative Jenkins pipeline with a docker-verify stage that prints the docker version, using the Hello World template and an any agent as the first stage.
Extend the Jenkins declarative pipeline by adding a get-verify stage that runs git --version and docker version as pre-checks, configures the stage, and reviews logs to confirm versions.
Set up a password on your GitLab account, copy the declarative pipeline code from Jenkins, create a Jenkins file in GitLab, and commit it to enable future GitLab Jenkins integration.
Integrate your GitLab project with Jenkins by using a declarative pipeline from SCM, supply GitLab credentials and main branch, and run the Jenkinsfile from GitLab.
Install the Blue Ocean plugin in Jenkins from manage plugins, restart Jenkins, then use the Blue Ocean UI to visualize and manage pipelines with stages and logs.
Create a docker file in your GitLab repository using the attached Apache-based docker file, label it DevOps, and commit changes to enable building a custom image with future modifications.
Update the Jenkins declarative pipeline to tag the Docker build with the build number, using env.BUILD_NUMBER in a double-quoted command to create a unique image tag on each run.
Learn to add a timeout in a Jenkins declarative pipeline verify stage, set 10 seconds, run sleep 30 seconds, observe the pipeline fail, and preserve three retries and data section.
Implement a declarative Jenkins pipeline with a pre-check stage that runs docker verify and get verify in parallel.
Learn to add a timestamp to Jenkins declarative pipelines by configuring options at the pipeline level, so every console log line includes a time stamp for easier troubleshooting.
Set the discard value to ten, add sleep 30 in the Docker verify stage, and enable the disable concurrent builds option in a declarative Jenkins pipeline to prevent parallel runs.
Apply a Jenkins declarative pipeline when condition to run the docker build stage only on the test branch, after removing the sleep in verify and editing the Jenkins file.
Update the Jenkins declarative pipeline to trigger the docker build on the main branch by changing the when condition from test to main, then verify the new image.
Adds a docker deploy stage to the Jenkins declarative pipeline, running the built image with port 80 mapping. It lists containers and opens http access via inbound rules.
Learn how to add a manual approval in a Jenkins declarative pipeline to pause the Docker deploy stage with an input step, enabling controlled production deployments.
Add a Docker images cleanup stage to a Jenkins declarative pipeline after deploy, using Docker images prune to remove unused images and free disk space on a constrained environment.
Introduce the always post section in a Jenkins declarative pipeline to run after each pipeline. Show a cleanup and list all docker images in the post always block, committing changes.
Add an aborted post section in a Jenkins declarative pipeline to run commands like Docker ps when the pipeline is aborted, demonstrated by editing the Jenkinsfile and checking logs.
Update the docker build command in a Jenkins declarative pipeline and add a post failure step to remove all running containers when the build fails.
Correct docker build command in the Jenkinsfile's docker build stage and add a post success step that runs a localhost command to verify the container serves HTML on port zero.
Learn how to add a post cleanup stage to a Jenkins declarative pipeline to remove unused docker images, ensuring cleanup runs even after a failed build, by updating the Jenkinsfile.
Attach an AWS IAM role to the Jenkins EC2 instance to enable repository access, by selecting the role in the AWS console and updating the instance's IAM role.
Integrate the docker build stage into a Jenkins declarative pipeline by using repo push commands to login, build, tag, and push the image to the repository.
Update the Jenkins declarative pipeline deploy stage to pull the latest image from the ACR repository and deploy a container using that image, verifying access via the host IP.
Update the Dockerfile in the GitLab repository by copying the indexed html into the http image's default hosting path, ensuring the website loads on container startup.
Run the Jenkins declarative pipeline to build a Docker container that hosts a custom index.html demo page via an Apache image, and verify the live site.
Modify indexed html color to orange in GitLab, commit changes, and run the Jenkins declarative pipeline to trigger a fresh build and manual docker deployment, resulting in orange after deployment.
Create a production EC2 instance, install Docker, and deploy Docker images from the local Jenkins build to the production server, planning multiple stages in the pipeline.
Add a prod deploy stage to the Jenkins declarative pipeline to deploy a docker container to a production machine using the public IP and image, with local testing and approval.
Add a cleanup stage before production deploy in the declarative pipeline to kill old containers on the prod host via SSH agent, then deploy the new container.
Create a seed job in Jenkins as a freestyle project named seed-job, add a description, and save; future steps update it via the DSL script after plugin installation.
Update Jenkins configuration by approving scripts, enabling script security, and building the job; observe autopilot job creation with an empty DSL pipeline script, and prepare to add parameters.
Learn to update a Jenkins DSL pipeline to inject a description into an autopilot Dstl job, remotely configuring and saving the job so the description appears automatically.
Update the description of a Jenkins DSL pipeline Autopilot job by editing the DSL script, saving, and building to apply the new description.
Update a Jenkins DSL pipeline to make a job parameterized, adding a string parameter with default value and description, and run builds with parameters from the UI.
Add a shell step in a Jenkins DSL pipeline to the autopilot dstl job, run echo hello world, save, and build with parameters to see the console output.
Configure a Jenkins DSL pipeline to add timestamps to the console output by inserting a wrapper with a time stamp, saving, and enabling the setting in the autopilot CE job.
Update the display name of a Jenkins job using a DSL script, adding autopilot as the top display name. Verify the change on the dashboard after you build.
Integrate the git SCM into a Jenkins DSL pipeline by configuring a job with clone URL and main branch, then save and run the build to update repo and branch.
Learn to update existing plugins in Jenkins by navigating to manage plugins and the updates tab, selecting a plugin to download and install after restart, and rebooting to apply updates.
Open manage plugins in Jenkins, locate installed plugins in the install tab, click the red uninstall icon to mark removal, and reboot Jenkins to complete the uninstall.
Disable a Jenkins plugin without uninstalling by using Manage plugins, under the install tab, toggle the enabled state, and allow restart only when no jobs are running.
After the hands-on journey with Jenkins, terminate all aws resources, delete key pairs and security groups, and close your aws account to avoid future charges.
Hello Guys,
Welcome to the "Jenkins CI CD | 70 Tasks on Declarative Pipelines & DSL Jobs" Course, which is specifically designed for Hands-On purpose onto Jenkins Declarative Pipelines, DSL Scripts, and Other Jenkins Features.
It's 2022
Learning new skills by just watching video sessions is not enough !!
You will have to hustle and practice the skills by implementing new things and by doing a lot of mistakes...
So, this course will push you to solve industry standard CI/CD related tasks on Jenkins.
Jenkins Hands On - Journey will cover below sections and topics:
# Environment Setup
AWS Account Setup
VM Setup
Jenkins Setup
GitLab Account Setup
Docker Setup
# Jenkins Free Style Jobs - Tasks
Jenkins free-style jobs
Cron setup
Parameters
Timestamps
Disabling jobs
# Jenkins CI/CD using Declarative Pipelines - Tasks
Pipeline jobs setup
Docker builds
Retry
TimeOuts
TimeStamps
Stages/Steps Setup
Options
Conditions
Approvals
Post Actions
Deploy Stages
SSH Agents
Remote Production Deployments
Docker CI/CD
ECR Integration
# DSL Tasks
DSL Seed Jobs
DSL Plugins
New Job Setup
Parameters
Descriptions
Timestamps
Disable Jobs
# Jenkins Plugins Management Tasks
Install Plugins
Update Plugins
Remove Plugins
Restart Jenkins
Here are the steps that you need to follow while working on this course tasks:
Give your 100% to solve the given tasks
Search Online for Official Documentation
Still not sure, Solution videos are provided for every task
Still have queries ?, We are here, Reach out to us through Q/A Section
Jenkins CI CD Hands-On with 70 Pipelines & Live Project | Practice Jenkins Declarative Pipelines, DSL & Jenkins Features
For all the tasks on Declarative Pipelines, DSL Pipelines, and Free Style Jobs, solutions will be provided just after every question.
You can also practice other Jenkins CI CD Projects after this course to enhance your skill set on Jenkins.
This course also includes a session on "How to delete the EC2 Machines on AWS and How to Terminate the Free Tier Account"
We are also offering other Hands On Courses on:
Bash Scripting Practice with 100 Tasks and 10 Live Projects
Gitlab CI CD Hands On | Build your own 50 Gitlab Pipelines
Master the Ansible by Solving 50 Ansible Playbooks Tasks
Learn Docker by doing with 50 Hands On Tasks and CI/CD Setup
Learn AWS LEX with Live Project, Slack Integration and CI/CD
#Jenkins #CI/CD #DevOps #ContinuousIntegration #ContinuousDeployment #Automation #SoftwareDevelopment #JenkinsPipeline #JenkinsJobs #DeclarativePipelines #DSL #DevOpsTools #DevOpsEngineering #BuildAutomation #DeploymentAutomation #ConfigurationManagement #InfrastructureAsCode #VersionControl #Testing #Deployment #Integration #DevOpsPractices #DevOpsCulture
All the Best Guys !!
Keep Learning and Keep Exploring !!
AutoPilot DevOps