jenkins

 

 1.下载文件http://mirrors.shu.edu.cn/jenkins/war-stable/2.89.3/jenkins.war    jenkins.war,拷贝tomcat webapps,目录

2.网页打开输入密码,密码在tomcat log文件里面

3.安装插件


二、sonarqube

unzip -q sonarqube-6.7.1.zip /usr/


不能用ROOT,改为其他用户

useradd  -g root
passwd

修改 SonarQube 配置

# Permissions to create tables, indices and triggers must be granted to JDBC user.
# The schema must be created first.
sonar.jdbc.username=sonar
sonar.jdbc.password=Sonar6.2


#----- Embedded Database (default)
# H2 embedded database server listening port, defaults to 9092
#sonar.embeddedDatabase.port=9092



#----- MySQL 5.6 or greater
# Only InnoDB storage engine is supported (not myISAM).
# Only the bundled driver is supported. It can not be changed.
sonar.jdbc.url=jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8&rewriteBatchedStatements=true&useConfigs=maxPerformance&useSSL=false





# Binding IP address. For servers with more than one IP address, this property specifies which
# address will be used for listening on the specified ports.
# By default, ports will be used on all IP addresses associated with the server.
sonar.web.host=0.0.0.0


# Web context. When set, it must start with forward slash (for example /sonarqube).
# The default value is root context (empty value).
sonar.web.context=/sonar
# TCP port for incoming HTTP connections. Default value is 9000.
sonar.web.port=9000


修改文件所有者 chown -R k:root .

启动服务

  /opt/sonarqube-6.2/bin/linux-x86-64/sonar.sh stop ## 停止服务
  /opt/sonarqube-6.2/bin/linux-x86-64/sonar.sh start ## 启动服务
  /opt/sonarqube-6.2/bin/linux-x86-64/sonar.sh restart ## 重启服务
  /opt/sonarqube-6.2/bin/linux-x86-64/sonar.sh console ## 控制台启动
  tail -f /opt/sonarqube-6.2/logs/sonar.log ## 查看日志

Execute the SonarQube Scanner for Gradle from your computer

Running a SonarQube analysis with Gradle is straighforward. You just need to declare the org.sonarqube plugin in your build.gradle file:

plugins {
  id "org.sonarqube" version "2.5"
}

and run the following command:

./gradlew sonarqube \
  -Dsonar.host.url=http://192.168.0.101:9000/sonar \
  -Dsonar.login=cdf79b8ec94f0c67963dc32edfb7c1c79748ac53

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值