作者 yangfu

1.修改环境变量

@@ -79,6 +79,8 @@ spec: @@ -79,6 +79,8 @@ spec:
79 configMapKeyRef: 79 configMapKeyRef:
80 name: suplus-config 80 name: suplus-config
81 key: mysql.password 81 key: mysql.password
  82 + - name: MYSQL_DB_NAME
  83 + value: "mmm_open"
82 - name: RUN_MODE 84 - name: RUN_MODE
83 value: "prod" 85 value: "prod"
84 - name: LOG_LEVEL 86 - name: LOG_LEVEL
@@ -15,6 +15,7 @@ func init() { @@ -15,6 +15,7 @@ func init() {
15 log.Error(fmt.Sprintf("【MYSQL】注册数据库失败:%v source:%v", err, constant.MYSQL_DATA_SOURCE)) 15 log.Error(fmt.Sprintf("【MYSQL】注册数据库失败:%v source:%v", err, constant.MYSQL_DATA_SOURCE))
16 return 16 return
17 } 17 }
  18 + log.Debug(fmt.Sprintf("【MYSQL】注册数据库:%v", constant.MYSQL_DATA_SOURCE))
18 orm.SetMaxIdleConns(aliasName, constant.MYSQL_MAX_IDLE) 19 orm.SetMaxIdleConns(aliasName, constant.MYSQL_MAX_IDLE)
19 orm.SetMaxOpenConns(aliasName, constant.MYSQL_MAX_OPEN) 20 orm.SetMaxOpenConns(aliasName, constant.MYSQL_MAX_OPEN)
20 } 21 }