Storage
Together with the database topic, this topic is surely among the most important ones. Both because storage will become the primary cost source at some point and also needs to deliver high performance, as the repository data is queried a lot.
Object Storage
Section titled “Object Storage”CodeFloe uses Impossible Cloud as its S3-compatible object-storage provider.
The production buckets are hosted in Impossible Cloud’s eu-central-2 region.
Forgejo assets such as packages, avatars, and attachments are stored there, as are off-site service backups.
Git repository data remains on CodeFloe’s own servers and is copied to object storage only as part of the backup system.
Off-site backups are encrypted before they are uploaded, so Impossible Cloud does not receive plaintext backup contents.
Object storage keeps less latency-sensitive data off the primary repository disks and reduces storage costs without changing how users access it.
High Availability Storage
Section titled “High Availability Storage”As the repository files are stored on disk, disk speed matters. Also, a HA-based architecture is required to prevent hardware failures and allow for seamless node updates. This is why we are opting for a Ceph cluster across the three nodes, which we are currently working on. Right now, the Git service is running on a single node with frequent backups.
With all the HA ideas in mind, there is still a lot of work to be done on the Forgejo side. Having a HA-storage setup and a HA-database is only half the battle. Forgejo is not yet HA-ready, i.e. custom adaptions are required to make the individual components (queue, cache, cron) work reliably in HA mode.