Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
ollama
Commits
a5ccf742
Commit
a5ccf742
authored
Nov 16, 2023
by
Michael Yang
Committed by
Jeffrey Morgan
Nov 16, 2023
Browse files
fix cross repo mounts
parent
e33ef391
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
server/upload.go
server/upload.go
+8
-0
No files found.
server/upload.go
View file @
a5ccf742
...
...
@@ -77,6 +77,14 @@ func (b *blobUpload) Prepare(ctx context.Context, requestURL *url.URL, opts *Reg
b
.
Total
=
fi
.
Size
()
// http.StatusCreated indicates a blob has been mounted
// ref: https://distribution.github.io/distribution/spec/api/#cross-repository-blob-mount
if
resp
.
StatusCode
==
http
.
StatusCreated
{
b
.
Completed
.
Store
(
b
.
Total
)
b
.
done
=
true
return
nil
}
var
size
=
b
.
Total
/
numUploadParts
switch
{
case
size
<
minUploadPartSize
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment