add object prefix in gcs store
This commit is contained in:
parent
fd2926cf60
commit
600f4fc939
|
@ -14,13 +14,14 @@ import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"fmt"
|
"fmt"
|
||||||
"golang.org/x/net/context"
|
|
||||||
"io"
|
"io"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
"sync"
|
"sync"
|
||||||
"sync/atomic"
|
"sync/atomic"
|
||||||
|
|
||||||
|
"golang.org/x/net/context"
|
||||||
|
|
||||||
"cloud.google.com/go/storage"
|
"cloud.google.com/go/storage"
|
||||||
"github.com/tus/tusd"
|
"github.com/tus/tusd"
|
||||||
"github.com/tus/tusd/uid"
|
"github.com/tus/tusd/uid"
|
||||||
|
@ -32,6 +33,11 @@ type GCSStore struct {
|
||||||
// Specifies the GCS bucket that uploads will be stored in
|
// Specifies the GCS bucket that uploads will be stored in
|
||||||
Bucket string
|
Bucket string
|
||||||
|
|
||||||
|
// ObjectPrefix is prepended to the name of each GCS object that is created.
|
||||||
|
// It can be used to create a pseudo-directory structure in the bucket,
|
||||||
|
// e.g. "path/to/my/uploads".
|
||||||
|
ObjectPrefix string
|
||||||
|
|
||||||
// Service specifies an interface used to communicate with the Google
|
// Service specifies an interface used to communicate with the Google
|
||||||
// cloud storage backend. Implementation can be seen in gcsservice file.
|
// cloud storage backend. Implementation can be seen in gcsservice file.
|
||||||
Service GCSAPI
|
Service GCSAPI
|
||||||
|
|
Loading…
Reference in New Issue