mirror of
https://github.com/HChaZZY/alist.git
synced 2025-12-20 00:56:43 +08:00
feat: stand-alone port s3 server (#6242)
* feat: single port s3 server * fix: unable to PUT files if not in root dir
This commit is contained in:
@@ -11,7 +11,7 @@ import (
|
||||
)
|
||||
|
||||
// Make a new S3 Server to serve the remote
|
||||
func NewServer(ctx context.Context, authpair []string) (h http.Handler, err error) {
|
||||
func NewServer(ctx context.Context) (h http.Handler, err error) {
|
||||
var newLogger logger
|
||||
faker := gofakes3.New(
|
||||
newBackend(),
|
||||
@@ -19,7 +19,7 @@ func NewServer(ctx context.Context, authpair []string) (h http.Handler, err erro
|
||||
gofakes3.WithLogger(newLogger),
|
||||
gofakes3.WithRequestID(rand.Uint64()),
|
||||
gofakes3.WithoutVersioning(),
|
||||
gofakes3.WithV4Auth(authlistResolver(authpair)),
|
||||
gofakes3.WithV4Auth(authlistResolver()),
|
||||
gofakes3.WithIntegrityCheck(true), // Check Content-MD5 if supplied
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user