So I figured out how to do it myself. The solution involves two servers.
-
On the backup server, ensure there is a running instance of gitlab. This instance will get trashed.
-
On the backup server, delete the directory /var/opt/gitlab/postgresql
This action will corrupt gitlab. This is why it must be done on a backup server. -
Copy the “restored” data to the backup gitlab server.
example: cp -ar /RESTORE/var/opt/gitlab/postgresql /var/opt/gitlab -
Change ownership if needed to gitlab-psql: sudo chown -R gitlab-psql /var/opt/gitlab/postgresql
-
Perform gitlab-ctl reconfigure, gitlab-ctl restart.
-
Log into mattermost. Mattermost will work, but gitlab will not.
-
Perform a mattermost backup.
-
From there, I was able to take that backup and restore it on the primary server.