Posts

Sidebar Links in Jenkins Job

Image
Hello Everyone! Here I will give some real use cases where the Jenkins integration with Sidebar Links requirement for a Jenkins Project.  Case 1: Your project might have a complete build strategy defined and it is shared on a Confluence page or common documentation platform. This document need to be linked to the Jenkins Job. Case 2 : Your QA team want to have all the jobs which they want to access on a single page. Even though you have placed all the QA-related jobs into a View. The solution is using Sidebar Link to the View from the Job. Case 3: A QA team working on two different Product testings where you have the two separate Jobs, but in the Organization the jobs are grown where a listing of all jobs will make difficult to search for the second job. instead of searching for the second job if we have the second job on the first job page then QA team life will be easy.  How to use Sidebar Links in a Jenkins Job? Sidebar link can be used for linking following: Documentation...

Jenkins Manage Assign Roles - Role based Strategy

Image
Here I am finding a solution for the users who belong to QA must have access only to the QA-related jobs. In this post,  Situation IT Organizations includes multiple teams such as: QA, Release, Developer and DBA or Middleware Engineers  Jenkins Master - Container-based Default all users have the same authorization. I would like to share how to launch the Jenkins Master on a Docker Container. login with docker playground. As you have provision to Add Node from the left side click it. You will get a terminal to use for 4 hours to play with the Docker engine.   To run the Jenkins inside docker container name: Jenkins-master run in detached mode -d Port forwarding from container port 8080 to host 8081 and 50000 to 50001 Allocate disk space to run the Jenkins workspace use -v Docker image from Blue Ocean Let's launch the Jenkins container using below command: docker run --name jenkins-master -u root --rm \ -d -p 8081:8080 -p 50001:50000 \ -v ...

Kubernetes Services

Image
 Hello everyone !! In this post, we will discuss the Kubernetes Services, What, and How we can deploy the service on a Kubernetes cluster. What is Kubernetes Service? We have Kubernetes services for not to remember the pod IP address, it is more comfortable inter-connecting the pods using service names. Why we need Kubernetes Services? We will get to know once we deploy the following different kinds of Kubernetes services on your Kubernetes cluster. Types of Kubernetes Services NodePort ClusterIP Headless  Loadbalancer Kubernetes Service types NodePort The node port will be a port enabled on a Node per microservice application.  Let's have pod defination in myapp.yaml apiVersion: v1 kind: Pod metadata: name: myapp-pod labels: app: myapp spec: containers: - name: nginx-containers image: nginx Create the myapp pod using the above defination. Example nodeport.yaml file apiVersion: v1 kind: Service metadata: name: appservi...

Git log - commit history

Image
Here is the GitOps story! we started learning more depth of every GIT commit history using git CLI. In this post, we have touched some rea-time scenario-based question and answers with practical examples which are useful for other DevOps team members.  The best question to help release management - who worked on the critical program/script which is in the release process? This can be found using the git log command.  The most interesting story if someone left the company and need to know what he did in his last commit. Tracking changes all of them done by that particular user.  The git log having many options: sorting filtering output formatting Let's see in detail by with experimenting each with an example. How to get the git log in a "Sorting order"? Here we have a couple of sorted commit history commands.  Using the --pretty value with  Oneline to going to give you the log output in simplify format. git log --pretty=oneline The output combination of ...

Git install latest version on Oracle Linux

 Hey! In this post I would like to discuss about git installation on Oracle Linux. By default git from the yum repo version is older 1.8.2. To get used of the latest features of git needs to install the latest version of git. Currently, the git version is 2.30.1. But this experiment will be same further as well. Step 1: Navigate to a path where the git installer needs to download. cd /opt wget https://mirrors.edge.kernel.org/pub/software/scm/git/git-2.30.1.tar.gz #remove the default git version from yum repo yum remove git -y # extract the git tarball tar -zxf git-2.30.1.tar.gz cd git-2.30.1 Step 2: The prerequisites for git installation is as: # prerequisites yum install curl-devel expat-devel gettext-devel openssl-devel zlib-devel -y yum install gcc perl-ExtUtils-MakeMaker -y Step 3: Install the git version # installing latest version of git make prefix=/usr/local/git all make prefix=/usr/local/git install Step 4: Now all set, we need to have the latest git i...

Publishing to Docker hub your own Docker Images

Image
 Hey DevOps Engineer, In this post I would like to share my experiment on Docker image creation and pushing to the public repository. Docker Hub is the world's easiest way to create, manage, and deliver your images with the teams who are working for microservices applications that runs on containers. Docker Hub allows you to pull docker images that are built by other community members, organizations on the Hub.  Docker Hub is a cloud-based registry service that allows you to link to code repositories, build your images and test them, store manually pushed images, and links to Docker Cloud so you can deploy images to your docker hosts. Publishing custom Image to Docker Hub Steps to publish the image Please use the following steps: Register with Docker Hub Login to docker hub from your Docker Host  Commit and Pushing to Docker Hub registry Docker tag Create an account/ Docker ID. If you have already then signed into it. Login into the docker hub from the docker host  ...

Jenkins Slave on AWS EC2 instances with SSH configuration

Image
After c onfiguring the  Jenkins Maste r we need to configure the slave or agent on EC2 instance. There are various methods to connect with the Slave node. In this post,  I would like to share the SSH key-based remoting method. Pre-requisites Jenkins Master already Up and Running Java (JDK) installed on the Slave node Here we are in the slave machine and proceed with the following steps for configure a SSH based Jenkins slave. How to create user and generate ssh-key on Slave? Login to slave node terminal using ssh or PuTTY switch to root user.  useradd jenkins_slave mkdir -p /home/jenkins_slave usermod -d /home/jenkins_slave jenkins_slave tail -1 /etc/passwd # To check useradded to userlist Now switch to the newly created user 'jenkins_slave'. sudo su - jenkins_slave SSH Key generate for 'jenkins_slave' user with the following command: cd .ssh ssh-keygen -t rsa -N "" The above command will create two files in /home/jenkins_slave/.ssh folder id_rsa (p...