mirror of
https://github.com/andwati/zitadel.git
synced 2026-11-05 13:52:15 +00:00
feat: encryption keys in database (#3265)
* enable overwrite of adminUser fields in defaults.yaml * create schema and table * cli: create keys * cli: create keys * read encryptionkey from db * merge v2 * file names * cleanup defaults.yaml * remove custom errors * load encryptionKeys on start * cleanup * fix merge * update system defaults * fix error message
This commit is contained in:
@@ -0,0 +1 @@
|
||||
CREATE SCHEMA system;
|
||||
@@ -0,0 +1,6 @@
|
||||
CREATE TABLE system.encryption_keys (
|
||||
id TEXT NOT NULL
|
||||
, key TEXT NOT NULL
|
||||
|
||||
, PRIMARY KEY (id)
|
||||
);
|
||||
@@ -9,6 +9,8 @@ The sql-files in this folder initialize the ZITADEL database and user. These obj
|
||||
- 03_grant_user.sql: grants the user created before to have full access to its database. The user needs full access to the database because zitadel makes ddl/dml on runtime
|
||||
- 04_eventstore.sql: creates the schema needed for eventsourcing
|
||||
- 05_projections.sql: creates the schema needed to read the data
|
||||
- files 06_enable_hash_sharded_indexes.sql and 07_events_table.sql must run in the same session
|
||||
- 06_enable_hash_sharded_indexes.sql enables the [hash sharded index](https://www.cockroachlabs.com/docs/stable/hash-sharded-indexes.html) feature for this session
|
||||
- 07_events_table.sql creates the table for eventsourcing
|
||||
- 06_system.sql: creates the schema needed for ZITADEL itself
|
||||
- 07_encryption_keys_table.sql: creates the table for encryption keys (for event data)
|
||||
- files 08_enable_hash_sharded_indexes.sql and 09_events_table.sql must run in the same session
|
||||
- 08_enable_hash_sharded_indexes.sql enables the [hash sharded index](https://www.cockroachlabs.com/docs/stable/hash-sharded-indexes.html) feature for this session
|
||||
- 09_events_table.sql creates the table for eventsourcing
|
||||
|
||||
Reference in New Issue
Block a user