We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3740c4a commit b4a6cafCopy full SHA for b4a6caf
src/main/resources/application.properties
@@ -1,12 +1,14 @@
1
server.port=8080
2
spring.application.name=spring-boot-jwt-auth
3
4
-spring.datasource.url=jdbc:mysql://localhost:3306/testdb?useSSL=false
+spring.datasource.url=jdbc:mysql://localhost:3306/testdb
5
spring.datasource.username=root
6
spring.datasource.password=123456
7
8
spring.jpa.properties.hibernate.dialect=org.hibernate.dialect.MySQL5InnoDBDialect
9
spring.jpa.hibernate.ddl-auto=update
10
+spring.sql.init.mode=always
11
+spring.sql.init.schema-locations=classpath:init_roles.sql
12
13
# JWT Properties
14
bezkoder.app.jwtSecret=bezKoderSecretKey
src/main/resources/init_roles.sql
@@ -0,0 +1,5 @@
+INSERT INTO roles (name)
+VALUES ('ROLE_USER'),
+ ('ROLE_MODERATOR'),
+ ('ROLE_ADMIN') ON DUPLICATE KEY
+UPDATE name = name;
0 commit comments