mirror of
https://github.com/ajnart/homarr.git
synced 2026-01-30 19:29:17 +01:00
* feat: add api keys * chore: address pull request feedback --------- Co-authored-by: Meier Lukas <meierschlumpf@gmail.com>
9 lines
350 B
SQL
9 lines
350 B
SQL
CREATE TABLE `apiKey` (
|
|
`id` varchar(64) NOT NULL,
|
|
`apiKey` text NOT NULL,
|
|
`salt` text NOT NULL,
|
|
`userId` varchar(64) NOT NULL,
|
|
CONSTRAINT `apiKey_id` PRIMARY KEY(`id`)
|
|
);
|
|
--> statement-breakpoint
|
|
ALTER TABLE `apiKey` ADD CONSTRAINT `apiKey_userId_user_id_fk` FOREIGN KEY (`userId`) REFERENCES `user`(`id`) ON DELETE cascade ON UPDATE no action; |