'Repo still uses 8 GB of quota after force push to initial commit (empty repo)
- My gitlab repo was ~8GO
- To rewrite it completely with size optimisation the idea was to reset the remote to the first commit and force push (
git checkout <initial hash>; git push -f
) - Then rewrite the history locally reducing size with compression and LFC, then force push again.
The issue is that after doing git checkout <initial hash>; git push -f
the quota used on the repo remotely is still 8GO (and so I am not able to push the history as 8+X > Quota).
What can I do to make gitlab reprocess the quota ? I triggered the warehousing but without any result.
The expected result is: quota 1ko (initial commit)
Solution 1:[1]
GitLab holds onto refs in hidden areas that are not advertised. Therefore, even force-pushing to advertised refs will not shrink the repository size. In order to actually reduce repository storage used, you'll need to follow the procedure for purging files from repository history.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|---|
Solution 1 | sytech |