From 2d140ee1bf8897a6475f089d42d6a6ecaa4dbd7d Mon Sep 17 00:00:00 2001 From: xiongfeng Date: Mon, 1 Aug 2022 16:25:22 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/application-dev.yml | 12 ++++++------ src/main/resources/templates/login.html | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/resources/application-dev.yml b/src/main/resources/application-dev.yml index 75a2732..b82b514 100644 --- a/src/main/resources/application-dev.yml +++ b/src/main/resources/application-dev.yml @@ -10,19 +10,19 @@ spring: connection-test-query: SELECT 1 datasource: master: - url: jdbc:mysql://120.48.109.209:3306/xf-boot-base?useUnicode=true&characterEncoding=utf-8&allowPublicKeyRetrieval=true&useSSL=false&serverTimezone=Asia/Shanghai + url: jdbc:mysql://#{ip}:3306/xf-boot-base?useUnicode=true&characterEncoding=utf-8&allowPublicKeyRetrieval=true&useSSL=false&serverTimezone=Asia/Shanghai username: root - password: 123456 + password: #{密码} driver-class-name: com.mysql.cj.jdbc.Driver slave: - url: jdbc:mysql://120.48.109.209:3306/xf-boot-base?useUnicode=true&characterEncoding=utf-8&allowPublicKeyRetrieval=true&useSSL=false&serverTimezone=Asia/Shanghai + url: jdbc:mysql://#{ip}:3306/xf-boot-base?useUnicode=true&characterEncoding=utf-8&allowPublicKeyRetrieval=true&useSSL=false&serverTimezone=Asia/Shanghai username: root - password: 123456 + password: #{密码} driver-class-name: com.mysql.cj.jdbc.Driver redis: port: 6379 #Redis服务器连接的端口 - host: 120.48.109.209 # Redis服务器的地址 - password: 123456 # Redis服务器连接密码(默认为空) + host: #{ip} # Redis服务器的地址 + password: #{密码} # Redis服务器连接密码(默认为空) timeout: 5000 # 连接超时时间(毫秒) lettuce: #参考博客 https://blog.csdn.net/weixin_43944305/article/details/124322595 pool: diff --git a/src/main/resources/templates/login.html b/src/main/resources/templates/login.html index 5828405..880d0f8 100644 --- a/src/main/resources/templates/login.html +++ b/src/main/resources/templates/login.html @@ -54,7 +54,7 @@ var json = JSON.stringify(data); var cipher = this.encryptByPublicKey(json); console.log("密文 :" + cipher); - var url = "http://120.48.109.209:8088/user/login"; + var url = "http://#{ip}:8088/user/login"; axios.post(url, { encryptedData: cipher, })