{"id":239169,"date":"2022-04-11T09:08:23","date_gmt":"2022-04-11T01:08:23","guid":{"rendered":"https:\/\/lrxjmw.cn\/?p=239169"},"modified":"2022-03-29T12:09:08","modified_gmt":"2022-03-29T04:09:08","slug":"cas-sonar-linux","status":"publish","type":"post","link":"https:\/\/lrxjmw.cn\/cas-sonar-linux.html","title":{"rendered":"\u5355\u70b9\u767b\u5f55\u4e4bcas\u96c6\u6210sonar\u7684\u914d\u7f6e\u65b9\u6cd5\u8be6\u89e3"},"content":{"rendered":"
\u5bfc\u8bfb<\/td>\n | \u8fd9\u7bc7\u6587\u7ae0\u4e3b\u8981\u4ecb\u7ecd\u4e86\u5355\u70b9\u767b\u5f55\u4e4bcas\u96c6\u6210sonar\u7684\u76f8\u5173\u77e5\u8bc6\uff0c\u672c\u6587\u901a\u8fc7\u793a\u4f8b\u4ee3\u7801\u7ed9\u5927\u5bb6\u4ecb\u7ecd\u7684\u975e\u5e38\u8be6\u7ec6\uff0c\u5bf9\u5927\u5bb6\u7684\u5b66\u4e60\u6216\u5de5\u4f5c\u5177\u6709\u4e00\u5b9a\u7684\u53c2\u8003\u501f\u9274\u4ef7\u503c,\u9700\u8981\u7684\u670b\u53cb\u53ef\u4ee5\u53c2\u8003\u4e0b<\/strong><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n \u4e00\u3001\u4fee\u6539 sonar \u914d\u7f6e conf\/sonar.properties<\/strong><\/div>\n \u4fee\u6539 sonar \u914d\u7f6e\u6587\u4ef6 conf\/sonar.properties\uff1a<\/p>\n sonar.security.realm = cas \r\nsonar.authenticator.createUsers = true \r\n#sonar.cas.forceCasLogin = true \r\nsonar.cas.protocol = cas3 \r\nsonar.cas.casServerUrlPrefix = http:\/\/192.168.1.58:8080\/cas \r\nsonar.cas.casServerLoginUrl = http:\/\/192.168.1.58:8080\/cas\/login \r\nsonar.cas.casServerLogoutUrl = http:\/\/192.168.1.58:8080\/cas\/logout \r\nsonar.cas.sonarServerUrl = http:\/\/192.168.1.35:9200 \r\nsonar.cas.urlAfterCasRedirectCookieMaxAgeSeconds = 300 \r\nsonar.cas.sessionStorePath = \/opt\/sonarqube\/data\/sonarcas\/sessionstore \r\nsonar.cas.sessionStore.cleanUpIntervalInSeconds = 1800 \r\n \r\n# Specifies whether gateway=true should be sent to the CAS server. Default is false. \r\n# sonar.cas.sendGateway \r\n \r\n# Specifies how SonarQube groups should be replicated. A value of \"CAS\" always overwrites the user's local groups with \r\n# the group provided by CAS upon UI log-in. The user's local groups will be untouched, f. i. with the value \"sonarqube\".\r\n# Defaults to \"CAS\". \r\nsonar.cas.groupReplication = CAS \r\nsonar.cas.rolesAttributes = groups \r\nsonar.cas.fullNameAttribute = displayName \r\nsonar.cas.eMailAttribute = mail \r\nsonar.cas.saml11.toleranceMilliseconds = 1000 \r\nsonar.cas.disableCertValidation = true <\/pre>\n |