SonarQube代码质量管理平台安装与使用
作者:网络转载 发布时间:[ 2013/9/25 16:00:54 ] 推荐标签:
#vi sonar.properties
sonar.jdbc.username: sonar
sonar.jdbc.password: sonar
sonar.jdbc.url: jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8&rewriteBatchedStatements=true
# Optional properties
sonar.jdbc.driverClassName: com.mysql.jdbc.Driver
修改sonar-runner的配置文件
切换至sonar-runner的安装目录下,修改sonar-runner.properties
根据实际使用数据库情况取消相应注释
#Configure here general information about the environment, such as SonarQube DB details for example
#No information about specific project should appear here
#----- Default SonarQube server
sonar.host.url=http://localhost:9000
#----- PostgreSQL
#sonar.jdbc.url=jdbc:postgresql://localhost/sonar
#----- MySQL
sonar.jdbc.url=jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8
#----- Oracle
#sonar.jdbc.url=jdbc:oracle:thin:@localhost/XE
#----- Microsoft SQLServer
#sonar.jdbc.url=jdbc:jtds:sqlserver://localhost/sonar;SelectMethod=Cursor
#----- Global database settings
sonar.jdbc.username=sonar
sonar.jdbc.password=sonar
#----- Default source code encoding
sonar.sourceEncoding=UTF-8
#----- Security (when 'sonar.forceAuthentication' is set to 'true')
sonar.login=admin
sonar.password=admin
3.添加数据库驱动
除了Oracle数据库外,其它数据库驱动都默认已经提供了,且这些已添加的驱动是sonar支持的,因此不需要修改
如果是Oracle数据库,需要复制JDBC驱动至<install_directory>/extensions/jdbc-driver/oracle目录
4.启动服务
目录切换至sonar的<install_directory>/bin/linux-x86-64/目录,启动服务
#./sonar.sh start 启动服务
#./sonar.sh stop 停止服务
#./sonar.sh restart 重启服务
至此,sonar安装好了
访问http:\localhost:9000即可
5.sonar中文补丁包安装
中文包安装
安装中文补丁包可以通过访问http:\localhost:9000,打开sonar后,进入更新中心安装
或者下载中文补丁包后,放到SONARQUBE_HOME/extensions/plugins目录,然后重启SonarQube服务
相关推荐
更新发布
常用的选择回归测试的方式有哪些?
2022/6/14 16:14:27测试流程中需要重点把关几个过程?
2021/10/18 15:37:44性能测试的七种方法
2021/9/17 15:19:29全链路压测优化思路
2021/9/14 15:42:25性能测试流程浅谈
2021/5/28 17:25:47常见的APP性能测试指标
2021/5/8 17:01:11系统性能测试及调优前期准备
2021/4/15 14:41:29国内比较好用的5款测试管理工具
2021/3/25 17:23:31