痛点:上一篇的AWS部署的VNC不知为啥挂了,死活连不上,因此改申请京东云做部署Jenkins
预计阅读时间:20分钟
更新软件,安装桌面
yum -y update
yum -y groupinstall "X Window System"
yum -y groupinstall gnome
yum -y install firefox 添加用户,安装tigervnc-server并进行相应配置
sudo useradd awsgui
sudo passwd awsgui
yum -y install tigervnc-server
vncserver
vi /root/.vnc/xstartup
vi /etc/sysconfig/vncservers
vncserver 检查java版本,下载jenkins
java -version
yum -y install wget
wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
rpm --import https://jenkins-ci.org/redhat/jenkins-ci.org.key
yum install jenkins -y
chkconfig jenkins on 检查jenkins相应服务和日志
service jenkins start
service jenkins stop
service jenkins restart
service jenkins status
tailf /var/log/jenkins/jenkins.log
cat /etc/yum.repos.d/jenkins.repo 防火墙配置修改(京东云默认没有打开防火墙。。。)
#firewall-cmd --zone=public --add-port=/tcp --permanent
cat /var/lib/jenkins/secrets/initialAdminPassword
尝试VNC连接
然后本地打开浏览器进行连接,大功告成
参考链接:
【安装VNC】 http://gloriasilveira.com/installing-a-gui-on-an-ec2-rhel-7-instance.html
【Jenkins安装配置】
http://wiki.jikexueyuan.com/project/linux-in-eye-of-java/Jenkins-Install-And-Settings.html
https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+on+Red+Hat+distributions
【tightvnc 下载地址】
http://www.tightvnc.com/download.php