Skip to content

[Proposal] Gitea repository storage abstract #25070

Open
@lunny

Description

@lunny

Current status

Gitea's repositories are stored in a single directory that is configured via app.ini.

#24783 would like hot/cold storage. i.e. repo archived repository will be stored in a HDD but the hot repository will be stored in SSD

#22532 would like to store the repository in different directories with a hash

#13791 request a distributed git storages like gitaly

The problems

  • setting.Repository.RepoRootPath has been used by many places which fixed the usage to visit the repository
  • modules/git.Command has an option Dir which fixed the git command run directory

Resolution

  • First step, build an abstract level to visit repositories and avoid visit setting.Repository.RepoRootPath directly
  • Most function will accept a relative repository path
  • Refactor git.Command to visit the abstract level

Others

Some ideas are storing git repositories with repository id but not username/reponame, how to handle it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/proposalThe new feature has not been accepted yet but needs to be discussed first.type/refactoringExisting code has been cleaned up. There should be no new functionality.type/summaryThis issue aggregates a bunch of other issues

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions