ALTER TABLE ssh_credentials ADD COLUMN owner_project_id INTEGER REFERENCES projects(id) ON DELETE CASCADE;
CREATE INDEX idx_ssh_credentials_owner_project ON ssh_credentials(owner_scope, owner_project_id);
ALTER TABLE git_mirrors ADD COLUMN ssh_credential_id INTEGER REFERENCES ssh_credentials(id) ON DELETE SET NULL;
