Generate and store JWT secret in DB
This commit is contained in:
@@ -2,12 +2,6 @@ app:
|
||||
path-book: '/app/books'
|
||||
path-config: '/app/config'
|
||||
|
||||
security:
|
||||
jwt:
|
||||
secret: G6u4m3g7M/b93k7m9a1h1Kw4l3D+5WqXldpl4nTjl4s=
|
||||
expiration: 36000000 # 10 hours in milliseconds
|
||||
refreshExpiration: 604800000 # 7 days in milliseconds
|
||||
|
||||
spring:
|
||||
servlet:
|
||||
multipart:
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
CREATE TABLE IF NOT EXISTS jwt_secret
|
||||
(
|
||||
id SERIAL PRIMARY KEY,
|
||||
secret TEXT NOT NULL,
|
||||
created_at TIMESTAMP DEFAULT NOW()
|
||||
);
|
||||
|
||||
CREATE TABLE IF NOT EXISTS library
|
||||
(
|
||||
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||
|
||||
Reference in New Issue
Block a user