Registry directory permissions omnibus
Restored a backup of 9.5.3 onto a fresh install of 9.5.3 containing a number of docker images within the container registry. After the restore we were experiencing a 500 error when performing a docker push on any project hosting a private container.
Registry logs pointed to a permissions error trying to put an object in /var/opt/gitlab/gitlab-rails/shared/registry/*
After investigation, all of the files were owned by git:git
We performed the following expecting it to discover and correct the permissions:
sudo gitlab-ctl reconfigure
sudo gitlab-rake gitlab:check SANITIZE=true
With the help of @WarheadsSE it was determined that all files should be owned by registry:git which resolved the problem.