简体   繁体   English

无法在单个AWS实例上运行SonarQube和Jenkins

[英]Unable to run SonarQube and Jenkins on single instance of AWS

I have installed Jenkins and SonarQube on one of the EC2 instances on AWS. 我已经在AWS上的一个EC2实例上安装了Jenkins和SonarQube。 Under the security group, I have configured http, https, ssh and All TCP . 在安全组下,我配置了http,https,ssh和All TCP

For "All TCP" port range is 0-65535. 对于“所有TCP”,端口范围是0-65535。

I started SonarQube on http://ip:9000 and was able to interact with it. 我在http:// ip:9000上启动了SonarQube,并能够与其进行交互。 Next, I started Jenkins on http://ip:8080 and again I was able to interact with it, but once I switch back to the earlier URL ie SonarQube ( http://ip:9000 ) it got failed to start and it happened vice-versa as well. 接下来,我在http:// ip:8080上启动了Jenkins,再次能够与它进行交互,但是一旦我切换回早期的URL,即SonarQube( http:// ip:9000 ),它就无法启动,并且反之亦然。

  • For Security group, the source is My IP eg 11.22.333.44/55 对于安全组,源是我的IP, 例如11.22.333.44/55
  • Used "systemctl start jenkins" command to start Jenkins 使用“ systemctl start jenkins”命令启动Jenkins
  • Used "./sonar.sh start" command to start SonarQube 使用“ ./sonar.sh start”命令启动SonarQube
  • Amazon Machine Image (AMI) --> Red Hat Enterprise Linux 7.5 (HVM) 亚马逊机器映像(AMI)->红帽企业Linux 7.5(HVM)

First, you need to know the port in question (9000), stand up: 首先,您需要知道有问题的端口(9000),站起来:

netstat -ntl

Depending on the result, you will have to add the firewall rules for ipv4, within the Operating System: 根据结果​​,您将必须在操作系统内为ipv4添加防火墙规则:

sudo firewall-cmd --zone = public --permanent --list-ports
sudo firewall-cmd --zone = public --permanent --add-port = 9000 / tcp
sudo firewall-cmd --reload

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM