Handle database migration in CI

with csrf cookie stuff