创建jenkins案例
安装一下打包工具
[root@localhost workspace]# yum -y install maven
//把tomcat的包传到要用的虚拟机上
先做一个免密登录
[root@localhost ~]# ssh-keygen -t rsa
Generating public/private rsa key pair.
Enter file in which to save the key (/root/.ssh/id_rsa):
Created directory '/root/.ssh'.
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/id_rsa.
Your public key has been saved in /root/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:Am5mVU4Izc2G32wkrqiqg1P/0B08hPPwCdj7sDiXsUI root@localhost.localdomain
The key's randomart image is:
+---[RSA 3072]----+
| .+ =o |
| o=== . |
| o B+o= |
| . o Xo.+ |
| E.=.S. |
| .=.o.X o |
|.. o= * o |
|+ . .= |
|++ .. |
+----[SHA256]-----+
[root@localhost ~]# ssh-copy-id root@192.168.100.98
/usr/bin/ssh-copy-id: INFO: Source of key(s) to be installed: "/root/.ssh/id_rsa.pub"
The authenticity of host '192.168.100.98 (192.168.100.98)' can't be established.
ECDSA key fingerprint is SHA256:io11+klMBEh+b0sXEKTZIYMPKTKS4xi9JuDuhsftZf4