2022-05-15 15:43:37 +08:00
|
|
|
package s3api
|
|
|
|
|
|
|
|
import (
|
|
|
|
"context"
|
|
|
|
"github.com/chrislusf/seaweedfs/weed/pb/s3_pb"
|
|
|
|
)
|
|
|
|
|
2022-05-16 12:31:29 +08:00
|
|
|
func (s3a *S3ApiServer) Configure(ctx context.Context, request *s3_pb.S3ConfigureRequest) (*s3_pb.S3ConfigureResponse, error) {
|
2022-05-15 15:43:37 +08:00
|
|
|
|
2022-05-16 12:31:29 +08:00
|
|
|
if err := s3a.iam.LoadS3ApiConfigurationFromBytes(request.S3ConfigurationFileContent); err != nil {
|
2022-05-15 15:43:37 +08:00
|
|
|
return nil, err
|
|
|
|
}
|
|
|
|
|
2022-05-16 12:31:29 +08:00
|
|
|
return &s3_pb.S3ConfigureResponse{}, nil
|
2022-05-15 15:43:37 +08:00
|
|
|
|
|
|
|
}
|