close db connection after work to avoid 'remaining connection slots are...

close db connection after work to avoid 'remaining connection slots are reserved for non-replication superuser connections'
2 jobs for master in 5 minutes and 5 seconds (queued for 12 seconds)
Status Job ID Name Coverage
  Build
passed #113716
dind
build postgres

00:01:22

passed #113715
dind
build ui

00:05:05