Jenkins--Linux slave configuration __linux

Source: Internet
Author: User
Tags ssh

Description: The master machine is Windows, and a Linux machine is configured as a slave. This linux machine is for CentOS.

1, on the Linux slave configuration

① Create a user named Jenkins

#sudo/usr/sbin/useradd-m jenkins-d/home/jenkins

② Set the user Jenkins password

#sudo/usr/bin/passwd Jenkins
Enter a new password and a confirmation password as prompted.

③ Switch to Jenkins user

#su-jenkins

④ Create public/private key pair

#ssh-keygen-t RSA
Note: There are several inquiries in the middle, you can directly enter the return, where: key pair stored in the default/home/jenkins/.ssh directory, the password is empty.


⑤ Create Authorized_keys

#cd/home/jenkins/.ssh
#cat id_rsa.pub > Authorized_keys#chmod authorized_keys

⑥ copy of Id_rsa content

#cd/home/jenkins/.ssh
#cat Id_rsa
Description: Used when configured on the browser.

2, through the browser configuration

Access to the completed Jenkins through the browser.

① Configuration Voucher

"System Management"-> "Manage Credentials"-> "Add Credentials"-> "SSH Username with private key"



② Add and configure nodes

"System Management"-> "Management Node", enter the node name, select "Dump Slave".



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.