很明显,Failed to configure a DataSource: ‘url’ attribute is not specified and no embedded datasource could be configured.这里是没找到URL,说明根本没配置相关的属性
解决:在Application.yml配置文件中添加对应的即可
spring:
datasource:
# 当前数据源操作类型
type: com.alibaba.druid.pool.DruidDataSource
# mysql驱动类
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://localhost:3306/mCloudSql?useSSL=false&serverTimezone=UTC
username: root
password: root