建议增加导入本地仓库的功能 #14248

Closed
opened 2025-11-02 11:07:29 -06:00 by GiteaMirror · 3 comments
Owner

Originally created by @Tu5039 on GitHub (Mar 13, 2025).

Feature Description

1、现在从github、gitlab导入镜像仓库经常报错(网络等原因,各种配置均无果)
2、直接使用git clone --mirror成功率会高一点
3、因此建议增加从本地仓库导入的功能。即让使用者可以直接使用git clone --mirror将仓库镜像到本地,然后再通过类似gitea import_repo的能力完成仓库导入。这同时也提供了ssh模式导入镜像仓库的能力,因为使用者克隆过程是与导入过程解耦的。

Image

Screenshots

No response

Originally created by @Tu5039 on GitHub (Mar 13, 2025). ### Feature Description 1、现在从github、gitlab导入镜像仓库经常报错(网络等原因,各种配置均无果) 2、直接使用git clone --mirror成功率会高一点 3、因此建议增加从本地仓库导入的功能。即让使用者可以直接使用git clone --mirror将仓库镜像到本地,然后再通过类似gitea import_repo的能力完成仓库导入。这同时也提供了ssh模式导入镜像仓库的能力,因为使用者克隆过程是与导入过程解耦的。 ![Image](https://github.com/user-attachments/assets/2331e9c2-f6bb-4cdd-9fa2-60365d453a59) ### Screenshots _No response_
GiteaMirror added the type/proposal label 2025-11-02 11:07:29 -06:00
Author
Owner

@adlternative commented on GitHub (Mar 13, 2025):

服务网络不好那几乎没辙。一般让用户同步 git clone --mirror && git push --mirror 就行,git push --mirror 如果有问题就换 git push --heads && git push --tags

@adlternative commented on GitHub (Mar 13, 2025): 服务网络不好那几乎没辙。一般让用户同步 git clone --mirror <gitea> && git push --mirror <gitea> 就行,git push --mirror 如果有问题就换 git push --heads && git push --tags
Author
Owner

@hiifong commented on GitHub (Mar 13, 2025):

You can use the administrator account for local repository inclusion.

Image

Image

Image

@hiifong commented on GitHub (Mar 13, 2025): You can use the administrator account for local repository inclusion. ![Image](https://github.com/user-attachments/assets/23b97f47-e83f-482f-ac2e-bea6f89d0c6a) ![Image](https://github.com/user-attachments/assets/5770988b-bf24-491a-a762-48d191eed38d) ![Image](https://github.com/user-attachments/assets/684b1c6d-3006-4503-ba81-72cf1cf6a709)
Author
Owner

@lunny commented on GitHub (Mar 13, 2025):

This has been implemented. Just push to create.

@lunny commented on GitHub (Mar 13, 2025): This has been implemented. Just push to create.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#14248