Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upload LFS file directly when open SERVE_DIRECT config option #16776

Open
2 of 6 tasks
ABNER-1 opened this issue Aug 23, 2021 · 5 comments
Open
2 of 6 tasks

Upload LFS file directly when open SERVE_DIRECT config option #16776

ABNER-1 opened this issue Aug 23, 2021 · 5 comments
Labels
topic/lfs type/enhancement An improvement of existing functionality

Comments

@ABNER-1
Copy link
Contributor

ABNER-1 commented Aug 23, 2021

  • Gitea version (or commit ref): 1.15.0+rc3
  • Git version: git version 2.30.1
  • Operating system: ubuntu18.04
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
  • Log gist:

None

Description

The rest part of issuse #16711
Implement uploading lfs file when open SERVE_DIRECT config option.
some answers about details #16711 (comment)

@zeripath
Copy link
Contributor

Docker latest isn't a version.

Do you mean 1.15.0?

@noerw noerw added the type/enhancement An improvement of existing functionality label Aug 23, 2021
@ABNER-1
Copy link
Contributor Author

ABNER-1 commented Aug 23, 2021

I have updated the version of gitea

@ABNER-1
Copy link
Contributor Author

ABNER-1 commented Aug 23, 2021

I try to add x-amz-content-sha256, and this will help us to verify the upload file is consistent with the file sha256.
(I test by editing the source code of minio rudely. If sha256 is inconsistent in signature & header & file content sha, it cause 503 error, and will not found this resource in minio.)

However, I have some questions about this.

  1. Why verify action is optional?
  2. If have no verify action, how can gitea know the upload phase is over and try to write a meta information?

@lunny
Copy link
Member

lunny commented Aug 23, 2021

Hm, should we use another config option but not still use SERVE_DIRECT?

@ABNER-1
Copy link
Contributor Author

ABNER-1 commented Aug 23, 2021

I can accept it.

The config doc config-cheat-sheet describe it regardless of upload or download. But splitting it to two options is ok because they both may be suitable for different situation.

However, on my opinion, the SERVE_DIRECT may be called like UPLOAD/DOWNLOAD_SERVE_DIRECT because this will make user know more clearly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic/lfs type/enhancement An improvement of existing functionality
Projects
None yet
Development

No branches or pull requests

4 participants