Unverified Commit 7ec44d09 authored by irwinsun's avatar irwinsun Committed by GitHub
Browse files

Merge pull request #4771 from ddlin0719/issue_4572

CodeCC For 1.5 #4572
Showing with 0 additions and 186 deletions
+0 -186
......@@ -223,7 +223,6 @@ subprojects {
dependency "commons-io:commons-io:$commonsIOVersion"
dependency "org.apache.xmlrpc:xmlrpc-client:$xmlrpcVersion"
dependency "commons-httpclient:commons-httpclient:$commonsHttpclientVersion"
dependency "com.github.ulisesbocchio:jasypt-spring-boot-starter:$jasyptVersion"
dependencySet(group: "org.springframework.cloud", version: "$springConsulVersion") {
entry "spring-cloud-starter-consul-discovery"
entry "spring-cloud-starter-consul-core"
......
......@@ -4,7 +4,6 @@ dependencies {
compile project(":core:common:common-auth-api")
compile "org.springframework.boot:spring-boot-starter-amqp"
compile "org.springframework.boot:spring-boot-starter-aop"
compile "com.github.ulisesbocchio:jasypt-spring-boot-starter"
compile group: 'net.sf.json-lib', name: 'json-lib', classifier: "jdk15"
compile "org.apache.xmlrpc:xmlrpc-client"
}
/*
* Tencent is pleased to support the open source community by making BK-CI 蓝鲸持续集成平台 available.
*
* Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
*
* BK-CI 蓝鲸持续集成平台 is licensed under the MIT license.
*
* A copy of the MIT License is included in this file.
*
*
* Terms of the MIT License:
* ---------------------------------------------------
* Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy,
* modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
* LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
* NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package com.tencent.devops.common.web.jasypt
import com.tencent.devops.common.util.AESUtil
import org.jasypt.encryption.StringEncryptor
class DefaultEncryptor(private val key: String) : StringEncryptor {
override fun decrypt(message: String): String {
return AESUtil.decrypt(key, message)
}
override fun encrypt(message: String): String {
return AESUtil.encrypt(key, message)
}
}
\ No newline at end of file
# 服务配置文件模板
spring:
application:
name: defect${service-suffix}
desc: Defect Service
data:
mongodb:
uri: mongodb://__MONGODB_USER__:__MONGODB_PASS__@__MONGODB_IP__:__MONGODB_PORT__/db_defect?replicaSet=rs0&slaveOk=true
# 服务器端口配置,在同一台机器上部署多个微服务,端口号要不同 23910
server:
port: __CODECC_DEFECT_PORT__ # 服务端口
# 服务配置文件模板
spring:
application:
name: job${service-suffix}
desc: Job Service
data:
mongodb:
uri: mongodb://__MONGODB_USER__:__MONGODB_PASS__@__MONGODB_IP__:__MONGODB_PORT__/db_defect?replicaSet=rs0&slaveOk=true
server:
port: __CODECC_CODECCJOB_PORT__
\ No newline at end of file
# 服务配置文件模板
spring:
application:
name: quartz{service-suffix}
desc: Quartz Service
data:
mongodb:
uri: mongodb://__MONGODB_USER__:__MONGODB_PASS__@__MONGODB_IP__:__MONGODB_PORT__/db_task?replicaSet=rs0&slaveOk=true
# 服务器端口配置,在同一台机器上部署多个微服务,端口号要不同 23910
server:
port: __CODECC_TASK_PORT__ # 服务端口
time:
analysis:
maxhour: __CODECC_ANALYSIS_MAXHOUR__
devops:
imageName: __DEVOPS_DISPATCH_DOCER_DEFAULT_IMAGE_NAME__
retry:
attempt: __CODECC_RETRY_ATTEMPT__
interval: __CODECC_RETRY_INTERVAL__
codecc:
encryptor:
password: __CODECC_ENC_PWD__
quartz:
tag: prod
# 服务配置文件模板
spring:
application:
name: task${service-suffix}
desc: Task Service
data:
mongodb:
uri: mongodb://__MONGODB_USER__:__MONGODB_PASS__@__MONGODB_IP__:__MONGODB_PORT__/db_task?replicaSet=rs0&slaveOk=true
# 服务器端口配置,在同一台机器上部署多个微服务,端口号要不同 23910
server:
port: __CODECC_TASK_PORT__ # 服务端口
time:
analysis:
maxhour: __CODECC_ANALYSIS_MAXHOUR__
devops:
imageName: __DEVOPS_DISPATCH_DOCER_DEFAULT_IMAGE_NAME__
retry:
attempt: __CODECC_RETRY_ATTEMPT__
interval: __CODECC_RETRY_INTERVAL__
# Common config Template 重复的通用的配置抽离在到
spring:
application:
version: 4.0.0
# consul config do not need to change
redis:
host: __REDIS_IP__
port: __REDIS_PORT__
password: __REDIS_PASS__
pool:
maxActive: 16
maxWait: 2000
maxIdle: 16
minIdle: 0
rabbitmq:
virtual-host: __RABBITMQ_CODECC_VHOST__
username: __RABBITMQ_USERNAME__
password: __RABBITMQ_PASSWORD__
addresses: __RABBITMQ_HOST__:__RABBITMQ_PORT__
cloud:
consul:
discovery:
tags: __DEVOPS_CONSUL_TAG__
health-check-path: /management/health
heartbeat:
enabled: true
query-passing: true
preferIpAddress: true
port: __DEVOPS_CONSUL_PORT__
http:
encoding:
charset: UTF-8
enabled: true
force: true
# http concurrency
server:
servlet-path: /
undertow:
worker-threads: 100
# monitor path config
management:
security:
enabled: false
context-path: /management
auth:
envName: prod
url: __CODECC_AUTH_URL__
codeccCode: __APP_CODE__
codeccSecret: __APP_TOKEN__
systemId: __CODECC_SYSTEM_ID__
resourceType: __CODECC_RESOURCE_TYPE__
devopsGateway:
host: __DEVOPS_GATEWAY_HOST__:__DEVOPS_GATEWAY_PORT__
codeccGateway:
host: __CODECC_GATEWAY_HOST__:__CODECC_GATEWAY_PORT__
api: __CODECC_GATEWAY_HOST__:__CODECC_GATEWAY_PORT__
service-suffix: "-__BKCI_CONSUL_TAG__"
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment