feat:1. 增加dev环境时使用的配置文件 2. 使得容器部署到和mysql同一个docker网络下
This commit is contained in:
Vendored
+5
-1
@@ -31,7 +31,11 @@ pipeline {
|
|||||||
steps {
|
steps {
|
||||||
sh '''
|
sh '''
|
||||||
docker rm -f $CONTAINER_NAME || true
|
docker rm -f $CONTAINER_NAME || true
|
||||||
docker run -d --name $CONTAINER_NAME -p $HOST_PORT:$CONTAINER_PORT $IMAGE_NAME
|
docker run -d
|
||||||
|
--name $CONTAINER_NAME
|
||||||
|
--network mysql_default
|
||||||
|
-p $HOST_PORT:$CONTAINER_PORT $IMAGE_NAME
|
||||||
|
-e SPRING_PROFILES_ACTIVE=dev
|
||||||
'''
|
'''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
spring:
|
||||||
|
# 配置数据库
|
||||||
|
datasource:
|
||||||
|
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||||
|
url: jdbc:mysql://mysql8:3306/learning_progress_tracker?characterEncoding=utf-8&useSSL=false&serverTimezone=GMT%2B8
|
||||||
|
username: root
|
||||||
|
password: GUOxy5157
|
||||||
|
server:
|
||||||
|
port: 5157
|
||||||
@@ -0,0 +1,9 @@
|
|||||||
|
spring:
|
||||||
|
# 配置数据库
|
||||||
|
datasource:
|
||||||
|
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||||
|
url: jdbc:mysql://localhost:3306/learning_progress_tracker?characterEncoding=utf-8&useSSL=false&serverTimezone=GMT%2B8
|
||||||
|
username: root
|
||||||
|
password:
|
||||||
|
server:
|
||||||
|
port: 5157
|
||||||
@@ -1,12 +1,6 @@
|
|||||||
spring:
|
spring:
|
||||||
application:
|
application:
|
||||||
name: LearningProgressTracker
|
name: LearningProgressTracker
|
||||||
# 配置数据库
|
|
||||||
datasource:
|
|
||||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
|
||||||
url: jdbc:mysql://localhost:3306/learning_progress_tracker?characterEncoding=utf-8&useSSL=false&serverTimezone=GMT%2B8
|
|
||||||
username: root
|
|
||||||
password:
|
|
||||||
flyway:
|
flyway:
|
||||||
# 是否启动 flyway
|
# 是否启动 flyway
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -27,8 +21,6 @@ spring:
|
|||||||
jackson:
|
jackson:
|
||||||
time-zone: UTC
|
time-zone: UTC
|
||||||
date-format: yyyy-MM-dd'T'HH:mm:ss'Z'
|
date-format: yyyy-MM-dd'T'HH:mm:ss'Z'
|
||||||
server:
|
|
||||||
port: 8081
|
|
||||||
mybatis-plus:
|
mybatis-plus:
|
||||||
configuration:
|
configuration:
|
||||||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||||
|
|||||||
Reference in New Issue
Block a user