ProjectMirrorData project_id foreign key inconsistencies

Relevant issue: https://gitlab.com/gitlab-org/gitlab-ee/issues/5904

  1. [EE and CE] In MySQL project_id has a NOT NULL constraint while in Postgres it allows a null value
  2. [CE] The foreign key does not have a unique constraint while in EE it does.

\cc @DouweM @godfat

Edited by Tiago Botelho