Fix migration in SQL connector

I didn't realise quite what the migration mechanism was. Have understood
it now.
This commit is contained in:
Joel Speed 2018-02-15 10:02:03 +00:00
parent 433bb2afec
commit d38909831c
No known key found for this signature in database
GPG key ID: 6E80578D6751DEFB

View file

@ -100,6 +100,7 @@ var migrations = []migration{
claims_groups bytea not null, -- JSON array of strings
connector_id text not null,
connector_data bytea,
expiry timestamptz not null
);`,
@ -118,6 +119,7 @@ var migrations = []migration{
claims_groups bytea not null, -- JSON array of strings
connector_id text not null,
connector_data bytea,
expiry timestamptz not null
);`,
@ -134,7 +136,8 @@ var migrations = []migration{
claims_email_verified boolean not null,
claims_groups bytea not null, -- JSON array of strings
connector_id text not null
connector_id text not null,
connector_data bytea
);`,
`
create table password (
@ -172,7 +175,6 @@ var migrations = []migration{
user_id text not null,
conn_id text not null,
refresh bytea not null,
connector_data bytea not null,
PRIMARY KEY (user_id, conn_id)
);`,
},
@ -200,4 +202,11 @@ var migrations = []migration{
add column claims_preferred_username text not null default '';`,
},
},
{
stmts: []string{`
alter table offline_session
add column connector_data bytea not null default '';
`,
},
},
}