Skip to content

Commit 882cd60

Browse files
migration (#5383)
1 parent 07234c7 commit 882cd60

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

scripts/sql/260_gitops_ssh.down.sql

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
ALTER TABLE public.gitops_config DROP COLUMN IF EXISTS ssh_key;
2+
ALTER TABLE public.gitops_config DROP COLUMN IF EXISTS auth_mode;
3+
ALTER TABLE public.gitops_config ALTER COLUMN "token" SET NOT NULL;
4+
ALTER TABLE public.gitops_config ALTER COLUMN "host" SET NOT NULL;
5+
ALTER TABLE public.gitops_config DROP COLUMN IF EXISTS ssh_host;

scripts/sql/260_gitops_ssh.up.sql

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
ALTER TABLE public.gitops_config ADD COLUMN IF NOT EXISTS ssh_key text;
2+
ALTER TABLE public.gitops_config ADD COLUMN IF NOT EXISTS auth_mode text;
3+
ALTER TABLE public.gitops_config ALTER COLUMN "token" DROP NOT NULL;
4+
ALTER TABLE public.gitops_config ALTER COLUMN "host" DROP NOT NULL;
5+
ALTER TABLE public.gitops_config ADD ssh_host varchar(250) NULL;
6+
7+

0 commit comments

Comments
 (0)