From 569cea4ab8a4f592b7e9e1a9784d8daf915db58e Mon Sep 17 00:00:00 2001 From: BugKing Date: Mon, 28 Nov 2022 14:26:16 +0800 Subject: [PATCH] Refine configuration for dev profile (#2753) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit #### What type of PR is this? /kind improvement #### What this PR does / why we need it: 1. 增加console代理配置,默认代理到`http://localhost:3000/`。 2. 增加用户名密码初始化配置。 3. 增加win profile,指定与dev profile中不同的r2dbc url,windows环境下调试时可以使用 `dev,win` profile。 #### Does this PR introduce a user-facing change? ```release-note None ``` --- src/main/resources/application-dev.yaml | 7 +++++++ src/main/resources/application-win.yaml | 5 +++++ 2 files changed, 12 insertions(+) create mode 100644 src/main/resources/application-win.yaml diff --git a/src/main/resources/application-dev.yaml b/src/main/resources/application-dev.yaml index e6fac9b06..031969d6a 100644 --- a/src/main/resources/application-dev.yaml +++ b/src/main/resources/application-dev.yaml @@ -9,7 +9,14 @@ spring: cache: false halo: + console: + proxy: + endpoint: http://localhost:3000/ + enabled: true security: + initializer: + super-admin-username: admin + super-admin-password: admin oauth2: jwt: jwsAlgorithm: rs512 diff --git a/src/main/resources/application-win.yaml b/src/main/resources/application-win.yaml new file mode 100644 index 000000000..5c8b12386 --- /dev/null +++ b/src/main/resources/application-win.yaml @@ -0,0 +1,5 @@ +spring: + r2dbc: + url: r2dbc:h2:file:///~/halo2-dev/db/halo-next?MODE=MySQL&DB_CLOSE_ON_EXIT=FALSE +halo: + work-dir: ${user.home}/halo2-dev \ No newline at end of file