Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

无法切换为mysql数据源 #6436

Closed
LockonS opened this issue Aug 3, 2024 · 3 comments
Closed

无法切换为mysql数据源 #6436

LockonS opened this issue Aug 3, 2024 · 3 comments
Labels
triage/needs-information Indicates an issue needs more information in order to work on it.

Comments

@LockonS
Copy link

LockonS commented Aug 3, 2024

System information

Version: 2.18
Database: MySQL/8.0.36

What is the project operation method?

Fat Jar

What happened?

使用systemd启动服务,在/home/halo/.halo2/application.yml 中数据库部分配置如下
启动服务后halo只会创建h2数据库,但是不会连接到mysql

spring:
  # 数据库配置,支持 MySQL、MariaDB、PostgreSQL、H2 Database,具体配置方式可以参考下面的数据库配置
  r2dbc:
    url: r2dbc:pool:mysql://localhost:3306/halo?characterEncoding=utf8&useSSL=false&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true
    username: halo
    password: HaloService-2024
  sql:
    init:
      mode: always
      # 需要配合 r2dbc 的配置进行改动
      platform: mysql

Reproduce Steps

No response

Relevant log output

No response

Additional information

No response

@ruibaby
Copy link
Member

ruibaby commented Aug 8, 2024

建议提供 systemd 的配置文件。

/triage needs-information

@f2c-ci-robot f2c-ci-robot bot added the triage/needs-information Indicates an issue needs more information in order to work on it. label Aug 8, 2024
@ruibaby
Copy link
Member

ruibaby commented Aug 26, 2024

/close

@f2c-ci-robot f2c-ci-robot bot closed this as completed Aug 26, 2024
Copy link

f2c-ci-robot bot commented Aug 26, 2024

@ruibaby: Closing this issue.

In response to this:

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@halo-dev halo-dev locked and limited conversation to collaborators Aug 26, 2024
@ruibaby ruibaby converted this issue into discussion #6521 Aug 26, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
triage/needs-information Indicates an issue needs more information in order to work on it.
Projects
None yet
Development

No branches or pull requests

2 participants