DevOps Classroom Series – 14/Feb/2021

Jenkins User Administration

  • Enabling and disabling global security on Jenkins
    • Navigate to Manage Jenkins => Configure Global Security Preview Preview
    • Authentication Methods in Jenkins are
      • Delegate to Servlet container
      • Jenkins own user database
      • LDAP: In this we configure jenkins to connect to our organizations active directory Preview Preview
      • Unix user/group database
  • Creating new users inside jenkins
    • Navigate to Manage Jenkins => Manage Users Preview Preview
  • Authorization Methods of Jenkins
    • image Preview
    • Anyone can do anything
    • Legacy moded: when we choos this mode Jenkins behaves the way it was before jenkins release 1.164. In Legacy mode jenkins will look for a user named Admin This user will have administrative privilege all the other users will be considered anonymous
    • Logged-in users can do anything
    • Matrix-based:
      • This is most widely used Authorization method in Jenkins Preview Preview
    • Project-based Matrix Authorization Strategy

Configuring High Availability for Jenkins

  • Jenkins Standalone set up looks as below Preview
  • To configure High Availability Preview

Distributed Builds in Jenkins

  • Lets consider the scenario as mentioned over here Refer Here Preview
  • Now lets configure one linux system as jenkins node
    • OS: ubuntu 18 os
    • Softwares: jdk8, maven
    • user: ubuntu and password authentication is enabled
  • Commands to be executed after login into ubuntu instance
sudo apt update
sudo apt install openjdk-8-jdk maven -y
  • In Jenkins to configure the nodes we have to choose the authentication strategy
    • ssh Preview Preview Preview Preview Preview
  • Now lets try to create a jenkins project which will run on node 1 Preview Preview Preview Preview Preview Preview
  • Now lets create one more centos node
    • sofwares: jdk 11 and maven
    • OS: centos 7
    • Authentication: username and key
  • Commands:
 sudo yum install java-11-openjdk git -y
 sudo yum install maven -y
  • Now add a node Preview
  • Add a credential and select ssh with private key Preview Preview Preview
  • Now lets create a jenkins job to build spring petclinic on this node Preview Preview

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About continuous learner

devops & cloud enthusiastic learner