add unique user and host constraint to db

This commit is contained in:
juancwu 2026-01-11 17:43:02 -05:00
commit 4e1ad1b285

View file

@ -5,7 +5,8 @@ CREATE TABLE IF NOT EXISTS keys (
host_pattern TEXT NOT NULL, host_pattern TEXT NOT NULL,
user_pattern TEXT NOT NULL, user_pattern TEXT NOT NULL,
encrypted_pem BLOB NOT NULL, encrypted_pem BLOB NOT NULL,
comment TEXT comment TEXT,
UNIQUE (user_pattern, host_pattern)
); );
-- +goose StatementEnd -- +goose StatementEnd