Preserve GitHub History Forever

Keep the entire story, not just the code

GitHub accounts get banned, repos go private, and owners rage-delete history. If you care about the full timeline—issues, releases, wiki—Gitea Mirror snapshots everything on a schedule so the story survives in your homelab.

Requirements

Step-by-step

1. Set archival-friendly defaults

In Configuration → Connections, open Content & Data:

2. Create an “Archive” organization in Gitea

  1. In Gitea, create an org like github-archive and grant read-only access to everyone who needs the history.
  2. Back in Gitea Mirror under Configuration → Connections, pick the Preserve structure strategy (or set a destination organization) so repos land in that archive org.
  3. Tighten permissions in Gitea—disable pushes for regular users so the archive stays immutable while the service updates it via its token.
Repositories dashboard in Gitea Mirror showing archived GitHub projects synced into Gitea.

Keep every GitHub project visible in the repositories dashboard while routing mirrors into a dedicated archive organization.

3. Choose retention & cadence

4. Record provenance

5. Back up the backup

Verify the archive

  1. Delete a draft issue on GitHub.
  2. Wait for the next sync; open the issue in Gitea—you should still see the original content.
  3. Compare git tag -l in both remotes to ensure releases match.
  4. Use git lfs ls-files to confirm large assets made it across.

Maintenance checklist

FAQ

Does this preserve issues, pull requests, and releases?

Yes—enable Mirror metadata and Mirror releases from Configuration → Connections → Content & Data. Pull requests copy as enriched issues, keeping discussion and labels.

What happens if a GitHub repo is deleted or goes private?

Turn on Handle orphaned repositories automatically and use Archive to keep a read-only copy locally. Delete enforces a strict mirror, removing the repo.

How much storage will I need long-term?

Plan for repo size plus attachments and LFS. Monitor the mirror’s data/ volume growth and consider ZFS/BTRFS snapshots or object storage for older archives.