Semaphore/db/sql/migrations/v2.11.5.sql
2024-12-15 00:49:02 +05:00

17 lines
616 B
SQL

create table project__terraform_inventory_alias(
`alias` varchar(100) primary key,
`project_id` int,
`inventory_id` int,
`auth_key_id` int,
foreign key (`project_id`) references project(`id`) on delete cascade,
foreign key (`inventory_id`) references project__inventory(`id`) on delete cascade,
foreign key (`auth_key_id`) references access_key(`id`)
);
create table project__terraform_inventory_state(
`id` integer primary key autoincrement,
`inventory_id` int,
`state` text,
`created` datetime NOT NULL,
foreign key (`inventory_id`) references project__inventory(`id`) on delete cascade
);