Implement mail aliases
This commit is contained in:
parent
f09444d832
commit
1c2b4c408e
3 changed files with 152 additions and 18 deletions
7
migrations/20231008140942_alias.sql
Normal file
7
migrations/20231008140942_alias.sql
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
-- Add migration script here
|
||||
CREATE TABLE alias (
|
||||
alias TEXT NOT NULL PRIMARY KEY,
|
||||
type mail_type NOT NULL CHECK (type = 'alias'),
|
||||
dest TEXT NOT NULL REFERENCES emails(mail),
|
||||
FOREIGN KEY (alias, type) REFERENCES emails (mail, type)
|
||||
);
|
||||
Loading…
Add table
Add a link
Reference in a new issue