Schedule script run
This commit is contained in:
parent
fc992b8bdc
commit
6d05152ab2
6 changed files with 162 additions and 7 deletions
20
sql/0013.sql
Normal file
20
sql/0013.sql
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
CREATE TABLE public.script_log (
|
||||
id serial NOT NULL,
|
||||
md5sum char(32) NOT NULL,
|
||||
source text NOT NULL,
|
||||
CONSTRAINT script_log_pk PRIMARY KEY (id)
|
||||
);
|
||||
|
||||
CREATE TABLE public.execution (
|
||||
id serial NOT NULL,
|
||||
time_start timestamptz NULL,
|
||||
script_log_id int4 NOT NULL,
|
||||
"data" jsonb NOT NULL,
|
||||
ssh varchar NOT NULL,
|
||||
time_end timestamptz NULL,
|
||||
output_stdout text NULL,
|
||||
output_stderr text NULL,
|
||||
exitcode int NULL,
|
||||
CONSTRAINT execution_pk PRIMARY KEY (id),
|
||||
CONSTRAINT execution_script_log_fk FOREIGN KEY (script_log_id) REFERENCES public.script_log(id) ON DELETE RESTRICT ON UPDATE RESTRICT
|
||||
);
|
||||
Loading…
Add table
Add a link
Reference in a new issue