Repacking / Garbage collection of pool repositories

We've recently had an issue raised by one of our contributors about our repositories becoming 'bloated' both on their local disk and in terms of the data needed to be transferred as part of 'git clone', which on investigation is being caused by regular updates made to the translations of our applications (which are stored in the po/ folder of the repository).

It appears that a simple "git gc --aggressive" rebuilds the delta packs and reduces the repository size in one case at least from 223M to 55M.

As we already perform housekeeping on our repositories, the actual parent repository should be fairly well packed (to contain nothing as everything is in the pool repository), however I suspect that Gitaly is not repacking the pool repositories as I can't see any logic to do so - which would lead to the issues noted above.

Can you confirm if that is the case and whether there is anything we can do to trigger this (even if it does have to be done from the Rails console with a bit of code we run manually every couple of months)?

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information