mirror of
https://github.com/rclone/rclone.git
synced 2026-01-05 18:13:17 +00:00
Compare commits
12 Commits
fix-9031-b
...
dependabot
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ed85edef50 | ||
|
|
3885800959 | ||
|
|
698373fd5c | ||
|
|
51b197c86f | ||
|
|
029ffd2761 | ||
|
|
f81cd7d279 | ||
|
|
1a0a4628d7 | ||
|
|
c10a4d465c | ||
|
|
3a6e07a613 | ||
|
|
c36f99d343 | ||
|
|
3e21a7261b | ||
|
|
fd439fab62 |
2
.github/workflows/build.yml
vendored
2
.github/workflows/build.yml
vendored
@@ -283,7 +283,7 @@ jobs:
|
|||||||
run: govulncheck ./...
|
run: govulncheck ./...
|
||||||
|
|
||||||
- name: Check Markdown format
|
- name: Check Markdown format
|
||||||
uses: DavidAnson/markdownlint-cli2-action@v20
|
uses: DavidAnson/markdownlint-cli2-action@v22
|
||||||
with:
|
with:
|
||||||
globs: |
|
globs: |
|
||||||
CONTRIBUTING.md
|
CONTRIBUTING.md
|
||||||
|
|||||||
@@ -412,8 +412,8 @@ the source file in the `Help:` field:
|
|||||||
- The `backenddocs` make target runs the Python script `bin/make_backend_docs.py`,
|
- The `backenddocs` make target runs the Python script `bin/make_backend_docs.py`,
|
||||||
and you can also run this directly, optionally with the name of a backend
|
and you can also run this directly, optionally with the name of a backend
|
||||||
as argument to only update the docs for a specific backend.
|
as argument to only update the docs for a specific backend.
|
||||||
- **Do not** commit the updated Markdown files. This operation is run as part of
|
- **Do not** commit the updated Markdown files. This operation is run as part
|
||||||
the release process. Since any manual changes in the autogenerated sections
|
of the release process. Since any manual changes in the autogenerated sections
|
||||||
of the Markdown files will then be lost, we have a pull request check that
|
of the Markdown files will then be lost, we have a pull request check that
|
||||||
reports error for any changes within the autogenerated sections. Should you
|
reports error for any changes within the autogenerated sections. Should you
|
||||||
have done manual changes outside of the autogenerated sections they must be
|
have done manual changes outside of the autogenerated sections they must be
|
||||||
@@ -580,7 +580,8 @@ remote or an fs.
|
|||||||
make sure we can encode any path name and `rclone info` to help determine the
|
make sure we can encode any path name and `rclone info` to help determine the
|
||||||
encodings needed
|
encodings needed
|
||||||
- `rclone purge -v TestRemote:rclone-info`
|
- `rclone purge -v TestRemote:rclone-info`
|
||||||
- `rclone test info --all --remote-encoding None -vv --write-json remote.json TestRemote:rclone-info`
|
- `rclone test info --all --remote-encoding None -vv --write-json remote.json
|
||||||
|
TestRemote:rclone-info`
|
||||||
- `go run cmd/test/info/internal/build_csv/main.go -o remote.csv remote.json`
|
- `go run cmd/test/info/internal/build_csv/main.go -o remote.csv remote.json`
|
||||||
- open `remote.csv` in a spreadsheet and examine
|
- open `remote.csv` in a spreadsheet and examine
|
||||||
|
|
||||||
|
|||||||
@@ -2,27 +2,27 @@
|
|||||||
|
|
||||||
Current active maintainers of rclone are:
|
Current active maintainers of rclone are:
|
||||||
|
|
||||||
| Name | GitHub ID | Specific Responsibilities |
|
| Name | GitHub ID | Specific Responsibilities |
|
||||||
| :--------------- | :---------------- | :-------------------------- |
|
| :--------------- | :---------------- | :------------------------------------- |
|
||||||
| Nick Craig-Wood | @ncw | overall project health |
|
| Nick Craig-Wood | @ncw | overall project health |
|
||||||
| Stefan Breunig | @breunigs | |
|
| Stefan Breunig | @breunigs | |
|
||||||
| Ishuah Kariuki | @ishuah | |
|
| Ishuah Kariuki | @ishuah | |
|
||||||
| Remus Bunduc | @remusb | cache backend |
|
| Remus Bunduc | @remusb | cache backend |
|
||||||
| Fabian Möller | @B4dM4n | |
|
| Fabian Möller | @B4dM4n | |
|
||||||
| Alex Chen | @Cnly | onedrive backend |
|
| Alex Chen | @Cnly | onedrive backend |
|
||||||
| Sandeep Ummadi | @sandeepkru | azureblob backend |
|
| Sandeep Ummadi | @sandeepkru | azureblob backend |
|
||||||
| Sebastian Bünger | @buengese | jottacloud, yandex & compress backends |
|
| Sebastian Bünger | @buengese | jottacloud, yandex & compress backends |
|
||||||
| Ivan Andreev | @ivandeex | chunker & mailru backends |
|
| Ivan Andreev | @ivandeex | chunker & mailru backends |
|
||||||
| Max Sum | @Max-Sum | union backend |
|
| Max Sum | @Max-Sum | union backend |
|
||||||
| Fred | @creativeprojects | seafile backend |
|
| Fred | @creativeprojects | seafile backend |
|
||||||
| Caleb Case | @calebcase | storj backend |
|
| Caleb Case | @calebcase | storj backend |
|
||||||
| wiserain | @wiserain | pikpak backend |
|
| wiserain | @wiserain | pikpak backend |
|
||||||
| albertony | @albertony | |
|
| albertony | @albertony | |
|
||||||
| Chun-Hung Tseng | @henrybear327 | Proton Drive Backend |
|
| Chun-Hung Tseng | @henrybear327 | Proton Drive Backend |
|
||||||
| Hideo Aoyama | @boukendesho | snap packaging |
|
| Hideo Aoyama | @boukendesho | snap packaging |
|
||||||
| nielash | @nielash | bisync |
|
| nielash | @nielash | bisync |
|
||||||
| Dan McArdle | @dmcardle | gitannex |
|
| Dan McArdle | @dmcardle | gitannex |
|
||||||
| Sam Harrison | @childish-sambino | filescom |
|
| Sam Harrison | @childish-sambino | filescom |
|
||||||
|
|
||||||
## This is a work in progress draft
|
## This is a work in progress draft
|
||||||
|
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import (
|
|||||||
"context"
|
"context"
|
||||||
"crypto/md5"
|
"crypto/md5"
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
|
"errors"
|
||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
"path"
|
"path"
|
||||||
@@ -24,7 +25,8 @@ import (
|
|||||||
var (
|
var (
|
||||||
hashType = hash.MD5
|
hashType = hash.MD5
|
||||||
// the object storage is persistent
|
// the object storage is persistent
|
||||||
buckets = newBucketsInfo()
|
buckets = newBucketsInfo()
|
||||||
|
errWriteOnly = errors.New("can't read when using --memory-discard")
|
||||||
)
|
)
|
||||||
|
|
||||||
// Register with Fs
|
// Register with Fs
|
||||||
@@ -33,12 +35,32 @@ func init() {
|
|||||||
Name: "memory",
|
Name: "memory",
|
||||||
Description: "In memory object storage system.",
|
Description: "In memory object storage system.",
|
||||||
NewFs: NewFs,
|
NewFs: NewFs,
|
||||||
Options: []fs.Option{},
|
Options: []fs.Option{{
|
||||||
|
Name: "discard",
|
||||||
|
Default: false,
|
||||||
|
Advanced: true,
|
||||||
|
Help: `If set all writes will be discarded and reads will return an error
|
||||||
|
|
||||||
|
If set then when files are uploaded the contents not be saved. The
|
||||||
|
files will appear to have been uploaded but will give an error on
|
||||||
|
read. Files will have their MD5 sum calculated on upload which takes
|
||||||
|
very little CPU time and allows the transfers to be checked.
|
||||||
|
|
||||||
|
This can be useful for testing performance.
|
||||||
|
|
||||||
|
Probably most easily used by using the connection string syntax:
|
||||||
|
|
||||||
|
:memory,discard:bucket
|
||||||
|
|
||||||
|
`,
|
||||||
|
}},
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// Options defines the configuration for this backend
|
// Options defines the configuration for this backend
|
||||||
type Options struct{}
|
type Options struct {
|
||||||
|
Discard bool `config:"discard"`
|
||||||
|
}
|
||||||
|
|
||||||
// Fs represents a remote memory server
|
// Fs represents a remote memory server
|
||||||
type Fs struct {
|
type Fs struct {
|
||||||
@@ -164,6 +186,7 @@ type objectData struct {
|
|||||||
hash string
|
hash string
|
||||||
mimeType string
|
mimeType string
|
||||||
data []byte
|
data []byte
|
||||||
|
size int64
|
||||||
}
|
}
|
||||||
|
|
||||||
// Object describes a memory object
|
// Object describes a memory object
|
||||||
@@ -558,7 +581,7 @@ func (o *Object) Hash(ctx context.Context, t hash.Type) (string, error) {
|
|||||||
if t != hashType {
|
if t != hashType {
|
||||||
return "", hash.ErrUnsupported
|
return "", hash.ErrUnsupported
|
||||||
}
|
}
|
||||||
if o.od.hash == "" {
|
if o.od.hash == "" && !o.fs.opt.Discard {
|
||||||
sum := md5.Sum(o.od.data)
|
sum := md5.Sum(o.od.data)
|
||||||
o.od.hash = hex.EncodeToString(sum[:])
|
o.od.hash = hex.EncodeToString(sum[:])
|
||||||
}
|
}
|
||||||
@@ -567,7 +590,7 @@ func (o *Object) Hash(ctx context.Context, t hash.Type) (string, error) {
|
|||||||
|
|
||||||
// Size returns the size of an object in bytes
|
// Size returns the size of an object in bytes
|
||||||
func (o *Object) Size() int64 {
|
func (o *Object) Size() int64 {
|
||||||
return int64(len(o.od.data))
|
return o.od.size
|
||||||
}
|
}
|
||||||
|
|
||||||
// ModTime returns the modification time of the object
|
// ModTime returns the modification time of the object
|
||||||
@@ -593,6 +616,9 @@ func (o *Object) Storable() bool {
|
|||||||
|
|
||||||
// Open an object for read
|
// Open an object for read
|
||||||
func (o *Object) Open(ctx context.Context, options ...fs.OpenOption) (in io.ReadCloser, err error) {
|
func (o *Object) Open(ctx context.Context, options ...fs.OpenOption) (in io.ReadCloser, err error) {
|
||||||
|
if o.fs.opt.Discard {
|
||||||
|
return nil, errWriteOnly
|
||||||
|
}
|
||||||
var offset, limit int64 = 0, -1
|
var offset, limit int64 = 0, -1
|
||||||
for _, option := range options {
|
for _, option := range options {
|
||||||
switch x := option.(type) {
|
switch x := option.(type) {
|
||||||
@@ -624,13 +650,24 @@ func (o *Object) Open(ctx context.Context, options ...fs.OpenOption) (in io.Read
|
|||||||
// The new object may have been created if an error is returned
|
// The new object may have been created if an error is returned
|
||||||
func (o *Object) Update(ctx context.Context, in io.Reader, src fs.ObjectInfo, options ...fs.OpenOption) (err error) {
|
func (o *Object) Update(ctx context.Context, in io.Reader, src fs.ObjectInfo, options ...fs.OpenOption) (err error) {
|
||||||
bucket, bucketPath := o.split()
|
bucket, bucketPath := o.split()
|
||||||
data, err := io.ReadAll(in)
|
var data []byte
|
||||||
|
var size int64
|
||||||
|
var hash string
|
||||||
|
if o.fs.opt.Discard {
|
||||||
|
h := md5.New()
|
||||||
|
size, err = io.Copy(h, in)
|
||||||
|
hash = hex.EncodeToString(h.Sum(nil))
|
||||||
|
} else {
|
||||||
|
data, err = io.ReadAll(in)
|
||||||
|
size = int64(len(data))
|
||||||
|
}
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("failed to update memory object: %w", err)
|
return fmt.Errorf("failed to update memory object: %w", err)
|
||||||
}
|
}
|
||||||
o.od = &objectData{
|
o.od = &objectData{
|
||||||
data: data,
|
data: data,
|
||||||
hash: "",
|
size: size,
|
||||||
|
hash: hash,
|
||||||
modTime: src.ModTime(ctx),
|
modTime: src.ModTime(ctx),
|
||||||
mimeType: fs.MimeType(ctx, src),
|
mimeType: fs.MimeType(ctx, src),
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -222,3 +222,11 @@ type UserInfo struct {
|
|||||||
} `json:"steps"`
|
} `json:"steps"`
|
||||||
} `json:"journey"`
|
} `json:"journey"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DiffResult is the response from /diff
|
||||||
|
type DiffResult struct {
|
||||||
|
Result int `json:"result"`
|
||||||
|
DiffID int64 `json:"diffid"`
|
||||||
|
Entries []map[string]any `json:"entries"`
|
||||||
|
Error string `json:"error"`
|
||||||
|
}
|
||||||
|
|||||||
@@ -171,6 +171,7 @@ type Fs struct {
|
|||||||
dirCache *dircache.DirCache // Map of directory path to directory id
|
dirCache *dircache.DirCache // Map of directory path to directory id
|
||||||
pacer *fs.Pacer // pacer for API calls
|
pacer *fs.Pacer // pacer for API calls
|
||||||
tokenRenewer *oauthutil.Renew // renew the token on expiry
|
tokenRenewer *oauthutil.Renew // renew the token on expiry
|
||||||
|
lastDiffID int64 // change tracking state for diff long-polling
|
||||||
}
|
}
|
||||||
|
|
||||||
// Object describes a pcloud object
|
// Object describes a pcloud object
|
||||||
@@ -1033,6 +1034,137 @@ func (f *Fs) Shutdown(ctx context.Context) error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ChangeNotify implements fs.Features.ChangeNotify
|
||||||
|
func (f *Fs) ChangeNotify(ctx context.Context, notify func(string, fs.EntryType), ch <-chan time.Duration) {
|
||||||
|
// Start long-poll loop in background
|
||||||
|
go f.changeNotifyLoop(ctx, notify, ch)
|
||||||
|
}
|
||||||
|
|
||||||
|
// changeNotifyLoop contains the blocking long-poll logic.
|
||||||
|
func (f *Fs) changeNotifyLoop(ctx context.Context, notify func(string, fs.EntryType), ch <-chan time.Duration) {
|
||||||
|
// Standard polling interval
|
||||||
|
interval := 30 * time.Second
|
||||||
|
|
||||||
|
// Start with diffID = 0 to get the current state
|
||||||
|
var diffID int64
|
||||||
|
|
||||||
|
// Helper to process changes from the diff API
|
||||||
|
handleChanges := func(entries []map[string]any) {
|
||||||
|
notifiedPaths := make(map[string]bool)
|
||||||
|
|
||||||
|
for _, entry := range entries {
|
||||||
|
meta, ok := entry["metadata"].(map[string]any)
|
||||||
|
if !ok {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
// Robust extraction of ParentFolderID
|
||||||
|
var pid int64
|
||||||
|
if val, ok := meta["parentfolderid"]; ok {
|
||||||
|
switch v := val.(type) {
|
||||||
|
case float64:
|
||||||
|
pid = int64(v)
|
||||||
|
case int64:
|
||||||
|
pid = v
|
||||||
|
case int:
|
||||||
|
pid = int64(v)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Resolve the path using dirCache.GetInv
|
||||||
|
// pCloud uses "d" prefix for directory IDs in cache, but API returns numbers
|
||||||
|
dirID := fmt.Sprintf("d%d", pid)
|
||||||
|
parentPath, ok := f.dirCache.GetInv(dirID)
|
||||||
|
|
||||||
|
if !ok {
|
||||||
|
// Parent not in cache, so we can ignore this change as it is outside
|
||||||
|
// of what the mount has seen or cares about.
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
name, _ := meta["name"].(string)
|
||||||
|
fullPath := path.Join(parentPath, name)
|
||||||
|
|
||||||
|
// Determine EntryType (File or Directory)
|
||||||
|
entryType := fs.EntryObject
|
||||||
|
if isFolder, ok := meta["isfolder"].(bool); ok && isFolder {
|
||||||
|
entryType = fs.EntryDirectory
|
||||||
|
}
|
||||||
|
|
||||||
|
// Deduplicate notifications for this batch
|
||||||
|
if !notifiedPaths[fullPath] {
|
||||||
|
fs.Debugf(f, "ChangeNotify: detected change in %q (type: %v)", fullPath, entryType)
|
||||||
|
notify(fullPath, entryType)
|
||||||
|
notifiedPaths[fullPath] = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for {
|
||||||
|
// Check context and channel
|
||||||
|
select {
|
||||||
|
case <-ctx.Done():
|
||||||
|
return
|
||||||
|
case newInterval, ok := <-ch:
|
||||||
|
if !ok {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
interval = newInterval
|
||||||
|
default:
|
||||||
|
}
|
||||||
|
|
||||||
|
// Setup /diff Request
|
||||||
|
opts := rest.Opts{
|
||||||
|
Method: "GET",
|
||||||
|
Path: "/diff",
|
||||||
|
Parameters: url.Values{},
|
||||||
|
}
|
||||||
|
|
||||||
|
if diffID != 0 {
|
||||||
|
opts.Parameters.Set("diffid", strconv.FormatInt(diffID, 10))
|
||||||
|
opts.Parameters.Set("block", "1")
|
||||||
|
} else {
|
||||||
|
opts.Parameters.Set("last", "0")
|
||||||
|
}
|
||||||
|
|
||||||
|
// Perform Long-Poll
|
||||||
|
// Timeout set to 90s (server usually blocks for 60s max)
|
||||||
|
reqCtx, cancel := context.WithTimeout(ctx, 90*time.Second)
|
||||||
|
var result api.DiffResult
|
||||||
|
|
||||||
|
_, err := f.srv.CallJSON(reqCtx, &opts, nil, &result)
|
||||||
|
cancel()
|
||||||
|
|
||||||
|
if err != nil {
|
||||||
|
if errors.Is(err, context.Canceled) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
// Ignore timeout errors as they are normal for long-polling
|
||||||
|
if !errors.Is(err, context.DeadlineExceeded) {
|
||||||
|
fs.Infof(f, "ChangeNotify: polling error: %v. Waiting %v.", err, interval)
|
||||||
|
time.Sleep(interval)
|
||||||
|
}
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
// If result is not 0, reset DiffID to resync
|
||||||
|
if result.Result != 0 {
|
||||||
|
diffID = 0
|
||||||
|
time.Sleep(2 * time.Second)
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
|
if result.DiffID != 0 {
|
||||||
|
diffID = result.DiffID
|
||||||
|
f.lastDiffID = diffID
|
||||||
|
}
|
||||||
|
|
||||||
|
if len(result.Entries) > 0 {
|
||||||
|
handleChanges(result.Entries)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Hashes returns the supported hash sets.
|
// Hashes returns the supported hash sets.
|
||||||
func (f *Fs) Hashes() hash.Set {
|
func (f *Fs) Hashes() hash.Set {
|
||||||
// EU region supports SHA1 and SHA256 (but rclone doesn't
|
// EU region supports SHA1 and SHA256 (but rclone doesn't
|
||||||
@@ -1401,6 +1533,7 @@ var (
|
|||||||
_ fs.ListPer = (*Fs)(nil)
|
_ fs.ListPer = (*Fs)(nil)
|
||||||
_ fs.Abouter = (*Fs)(nil)
|
_ fs.Abouter = (*Fs)(nil)
|
||||||
_ fs.Shutdowner = (*Fs)(nil)
|
_ fs.Shutdowner = (*Fs)(nil)
|
||||||
|
_ fs.ChangeNotifier = (*Fs)(nil)
|
||||||
_ fs.Object = (*Object)(nil)
|
_ fs.Object = (*Object)(nil)
|
||||||
_ fs.IDer = (*Object)(nil)
|
_ fs.IDer = (*Object)(nil)
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -2928,7 +2928,9 @@ func (f *Fs) Copy(ctx context.Context, src fs.Object, remote string) (fs.Object,
|
|||||||
req := s3.CopyObjectInput{
|
req := s3.CopyObjectInput{
|
||||||
MetadataDirective: types.MetadataDirectiveCopy,
|
MetadataDirective: types.MetadataDirectiveCopy,
|
||||||
}
|
}
|
||||||
|
if srcObj.storageClass != nil {
|
||||||
|
req.StorageClass = types.StorageClass(*srcObj.storageClass)
|
||||||
|
}
|
||||||
// Build upload options including headers and metadata
|
// Build upload options including headers and metadata
|
||||||
ci := fs.GetConfig(ctx)
|
ci := fs.GetConfig(ctx)
|
||||||
uploadOptions := fs.MetadataAsOpenOptions(ctx)
|
uploadOptions := fs.MetadataAsOpenOptions(ctx)
|
||||||
@@ -4501,7 +4503,12 @@ func (o *Object) prepareUpload(ctx context.Context, src fs.ObjectInfo, options [
|
|||||||
ACL: types.ObjectCannedACL(o.fs.opt.ACL),
|
ACL: types.ObjectCannedACL(o.fs.opt.ACL),
|
||||||
Key: &bucketPath,
|
Key: &bucketPath,
|
||||||
}
|
}
|
||||||
|
if tierObj, ok := src.(fs.GetTierer); ok {
|
||||||
|
tier := tierObj.GetTier()
|
||||||
|
if tier != "" {
|
||||||
|
ui.req.StorageClass = types.StorageClass(strings.ToUpper(tier))
|
||||||
|
}
|
||||||
|
}
|
||||||
// Fetch metadata if --metadata is in use
|
// Fetch metadata if --metadata is in use
|
||||||
meta, err := fs.GetMetadataOptions(ctx, o.fs, src, options)
|
meta, err := fs.GetMetadataOptions(ctx, o.fs, src, options)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|||||||
@@ -311,6 +311,8 @@ func (f *Fs) Move(ctx context.Context, src fs.Object, remote string) (fs.Object,
|
|||||||
o := &Object{
|
o := &Object{
|
||||||
fs: f,
|
fs: f,
|
||||||
remote: remote,
|
remote: remote,
|
||||||
|
mtime: srcObj.mtime,
|
||||||
|
size: srcObj.size,
|
||||||
}
|
}
|
||||||
fromFullPath := path.Join(src.Fs().Root(), srcObj.remote)
|
fromFullPath := path.Join(src.Fs().Root(), srcObj.remote)
|
||||||
toFullPath := path.Join(f.root, remote)
|
toFullPath := path.Join(f.root, remote)
|
||||||
@@ -367,7 +369,18 @@ func (f *Fs) DirMove(ctx context.Context, src fs.Fs, srcRemote, dstRemote string
|
|||||||
return fs.ErrorDirExists
|
return fs.ErrorDirExists
|
||||||
}
|
}
|
||||||
|
|
||||||
err := f.ensureParentDirectories(ctx, dstRemote)
|
fullPathSrc := f.buildFullPath(srcRemote)
|
||||||
|
fullPathSrcUnencoded, err := url.QueryUnescape(fullPathSrc)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
fullPathDstUnencoded, err := url.QueryUnescape(fullPath)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
|
||||||
|
err = f.ensureParentDirectories(ctx, dstRemote)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
@@ -378,6 +391,15 @@ func (f *Fs) DirMove(ctx context.Context, src fs.Fs, srcRemote, dstRemote string
|
|||||||
}
|
}
|
||||||
|
|
||||||
_, err = f.Move(ctx, o, dstRemote)
|
_, err = f.Move(ctx, o, dstRemote)
|
||||||
|
|
||||||
|
if err == nil {
|
||||||
|
|
||||||
|
f.createdDirMu.Lock()
|
||||||
|
f.createdDirs[fullPathSrcUnencoded] = false
|
||||||
|
f.createdDirs[fullPathDstUnencoded] = true
|
||||||
|
f.createdDirMu.Unlock()
|
||||||
|
}
|
||||||
|
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ Note that |ls| and |lsl| recurse by default - use |--max-depth 1| to stop the re
|
|||||||
The other list commands |lsd|,|lsf|,|lsjson| do not recurse by default -
|
The other list commands |lsd|,|lsf|,|lsjson| do not recurse by default -
|
||||||
use |-R| to make them recurse.
|
use |-R| to make them recurse.
|
||||||
|
|
||||||
|
List commands prefer a recursive method that uses more memory but fewer
|
||||||
|
transactions by default. Use |--disable ListR| to suppress the behavior.
|
||||||
|
See [|--fast-list|](/docs/#fast-list) for more details.
|
||||||
|
|
||||||
Listing a nonexistent directory will produce an error except for
|
Listing a nonexistent directory will produce an error except for
|
||||||
remotes which can't have empty directories (e.g. s3, swift, or gcs -
|
remotes which can't have empty directories (e.g. s3, swift, or gcs -
|
||||||
the bucket-based remotes).`, "|", "`")
|
the bucket-based remotes).`, "|", "`")
|
||||||
|
|||||||
@@ -13,6 +13,26 @@ docs](https://docs.aws.amazon.com/general/latest/gr/signature-version-4.html)).
|
|||||||
`--auth-key` is not provided then `serve s3` will allow anonymous
|
`--auth-key` is not provided then `serve s3` will allow anonymous
|
||||||
access.
|
access.
|
||||||
|
|
||||||
|
Like all rclone flags `--auth-key` can be set via environment
|
||||||
|
variables, in this case `RCLONE_AUTH_KEY`. Since this flag can be
|
||||||
|
repeated, the input to `RCLONE_AUTH_KEY` is CSV encoded. Because the
|
||||||
|
`accessKey,secretKey` has a comma in, this means it needs to be in
|
||||||
|
quotes.
|
||||||
|
|
||||||
|
```console
|
||||||
|
export RCLONE_AUTH_KEY='"user,pass"'
|
||||||
|
rclone serve s3 ...
|
||||||
|
```
|
||||||
|
|
||||||
|
Or to supply multiple identities:
|
||||||
|
|
||||||
|
```console
|
||||||
|
export RCLONE_AUTH_KEY='"user1,pass1","user2,pass2"'
|
||||||
|
rclone serve s3 ...
|
||||||
|
```
|
||||||
|
|
||||||
|
Setting this variable without quotes will produce an error.
|
||||||
|
|
||||||
Please note that some clients may require HTTPS endpoints. See [the
|
Please note that some clients may require HTTPS endpoints. See [the
|
||||||
SSL docs](#tls-ssl) for more information.
|
SSL docs](#tls-ssl) for more information.
|
||||||
|
|
||||||
|
|||||||
@@ -70,6 +70,11 @@ func newServer(ctx context.Context, f fs.Fs, opt *Options, vfsOpt *vfscommon.Opt
|
|||||||
w.s3Secret = getAuthSecret(opt.AuthKey)
|
w.s3Secret = getAuthSecret(opt.AuthKey)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
authList, err := authlistResolver(opt.AuthKey)
|
||||||
|
if err != nil {
|
||||||
|
return nil, fmt.Errorf("parsing auth list failed: %q", err)
|
||||||
|
}
|
||||||
|
|
||||||
var newLogger logger
|
var newLogger logger
|
||||||
w.faker = gofakes3.New(
|
w.faker = gofakes3.New(
|
||||||
newBackend(w),
|
newBackend(w),
|
||||||
@@ -77,7 +82,7 @@ func newServer(ctx context.Context, f fs.Fs, opt *Options, vfsOpt *vfscommon.Opt
|
|||||||
gofakes3.WithLogger(newLogger),
|
gofakes3.WithLogger(newLogger),
|
||||||
gofakes3.WithRequestID(rand.Uint64()),
|
gofakes3.WithRequestID(rand.Uint64()),
|
||||||
gofakes3.WithoutVersioning(),
|
gofakes3.WithoutVersioning(),
|
||||||
gofakes3.WithV4Auth(authlistResolver(opt.AuthKey)),
|
gofakes3.WithV4Auth(authList),
|
||||||
gofakes3.WithIntegrityCheck(true), // Check Content-MD5 if supplied
|
gofakes3.WithIntegrityCheck(true), // Check Content-MD5 if supplied
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -92,7 +97,7 @@ func newServer(ctx context.Context, f fs.Fs, opt *Options, vfsOpt *vfscommon.Opt
|
|||||||
w._vfs = vfs.New(f, vfsOpt)
|
w._vfs = vfs.New(f, vfsOpt)
|
||||||
|
|
||||||
if len(opt.AuthKey) > 0 {
|
if len(opt.AuthKey) > 0 {
|
||||||
w.faker.AddAuthKeys(authlistResolver(opt.AuthKey))
|
w.faker.AddAuthKeys(authList)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ package s3
|
|||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"encoding/hex"
|
"encoding/hex"
|
||||||
|
"errors"
|
||||||
"io"
|
"io"
|
||||||
"os"
|
"os"
|
||||||
"path"
|
"path"
|
||||||
@@ -125,15 +126,14 @@ func rmdirRecursive(p string, VFS *vfs.VFS) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func authlistResolver(list []string) map[string]string {
|
func authlistResolver(list []string) (map[string]string, error) {
|
||||||
authList := make(map[string]string)
|
authList := make(map[string]string)
|
||||||
for _, v := range list {
|
for _, v := range list {
|
||||||
parts := strings.Split(v, ",")
|
parts := strings.Split(v, ",")
|
||||||
if len(parts) != 2 {
|
if len(parts) != 2 {
|
||||||
fs.Infof(nil, "Ignored: invalid auth pair %s", v)
|
return nil, errors.New("invalid auth pair: expecting a single comma")
|
||||||
continue
|
|
||||||
}
|
}
|
||||||
authList[parts[0]] = parts[1]
|
authList[parts[0]] = parts[1]
|
||||||
}
|
}
|
||||||
return authList
|
return authList, nil
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1058,3 +1058,5 @@ put them back in again. -->
|
|||||||
- Tingsong Xu <tingsong.xu@rightcapital.com>
|
- Tingsong Xu <tingsong.xu@rightcapital.com>
|
||||||
- Jonas Tingeborn <134889+jojje@users.noreply.github.com>
|
- Jonas Tingeborn <134889+jojje@users.noreply.github.com>
|
||||||
- jhasse-shade <jacob@shade.inc>
|
- jhasse-shade <jacob@shade.inc>
|
||||||
|
- vyv03354 <VYV03354@nifty.ne.jp>
|
||||||
|
- masrlinu <masrlinu@users.noreply.github.com> <5259918+masrlinu@users.noreply.github.com>
|
||||||
|
|||||||
@@ -336,7 +336,7 @@ full new copy of the file.
|
|||||||
When mounting with `--read-only`, attempts to write to files will fail *silently*
|
When mounting with `--read-only`, attempts to write to files will fail *silently*
|
||||||
as opposed to with a clear warning as in macFUSE.
|
as opposed to with a clear warning as in macFUSE.
|
||||||
|
|
||||||
# Mounting on Linux
|
## Mounting on Linux
|
||||||
|
|
||||||
On newer versions of Ubuntu, you may encounter the following error when running
|
On newer versions of Ubuntu, you may encounter the following error when running
|
||||||
`rclone mount`:
|
`rclone mount`:
|
||||||
|
|||||||
@@ -751,21 +751,21 @@ object also.
|
|||||||
Here is a table of standard system metadata which, if appropriate, a
|
Here is a table of standard system metadata which, if appropriate, a
|
||||||
backend may implement.
|
backend may implement.
|
||||||
|
|
||||||
| key | description | example |
|
| key | description | example |
|
||||||
|---------------------|-------------|---------|
|
| --- | ----------- | ------- |
|
||||||
| mode | File type and mode: octal, unix style | 0100664 |
|
| mode | File type and mode: octal, unix style | 0100664 |
|
||||||
| uid | User ID of owner: decimal number | 500 |
|
| uid | User ID of owner: decimal number | 500 |
|
||||||
| gid | Group ID of owner: decimal number | 500 |
|
| gid | Group ID of owner: decimal number | 500 |
|
||||||
| rdev | Device ID (if special file) => hexadecimal | 0 |
|
| rdev | Device ID (if special file) => hexadecimal | 0 |
|
||||||
| atime | Time of last access: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
| atime | Time of last access: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
||||||
| mtime | Time of last modification: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
| mtime | Time of last modification: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
||||||
| btime | Time of file creation (birth): RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
| btime | Time of file creation (birth): RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
||||||
| utime | Time of file upload: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
| utime | Time of file upload: RFC 3339 | 2006-01-02T15:04:05.999999999Z07:00 |
|
||||||
| cache-control | Cache-Control header | no-cache |
|
| cache-control | Cache-Control header | no-cache |
|
||||||
| content-disposition | Content-Disposition header | inline |
|
| content-disposition | Content-Disposition header | inline |
|
||||||
| content-encoding | Content-Encoding header | gzip |
|
| content-encoding | Content-Encoding header | gzip |
|
||||||
| content-language | Content-Language header | en-US |
|
| content-language | Content-Language header | en-US |
|
||||||
| content-type | Content-Type header | text/plain |
|
| content-type | Content-Type header | text/plain |
|
||||||
|
|
||||||
The metadata keys `mtime` and `content-type` will take precedence if
|
The metadata keys `mtime` and `content-type` will take precedence if
|
||||||
supplied in the metadata over reading the `Content-Type` or
|
supplied in the metadata over reading the `Content-Type` or
|
||||||
@@ -1191,7 +1191,8 @@ on any OS, and the value is defined as following:
|
|||||||
|
|
||||||
- On Windows: `%HOME%` if defined, else `%USERPROFILE%`, or else `%HOMEDRIVE%\%HOMEPATH%`.
|
- On Windows: `%HOME%` if defined, else `%USERPROFILE%`, or else `%HOMEDRIVE%\%HOMEPATH%`.
|
||||||
- On Unix: `$HOME` if defined, else by looking up current user in OS-specific user
|
- On Unix: `$HOME` if defined, else by looking up current user in OS-specific user
|
||||||
database (e.g. passwd file), or else use the result from shell command `cd && pwd`.
|
database (e.g. passwd file), or else use the result from shell command
|
||||||
|
`cd && pwd`.
|
||||||
|
|
||||||
If you run `rclone config file` you will see where the default location is for
|
If you run `rclone config file` you will see where the default location is for
|
||||||
you. Running `rclone config touch` will ensure a configuration file exists,
|
you. Running `rclone config touch` will ensure a configuration file exists,
|
||||||
@@ -3438,7 +3439,7 @@ many items, the input is treated as a [CSV encoded](https://godoc.org/encoding/c
|
|||||||
string. For example
|
string. For example
|
||||||
|
|
||||||
| Environment variable | Equivalent options |
|
| Environment variable | Equivalent options |
|
||||||
|----------------------|--------------------|
|
| -------------------- | ------------------ |
|
||||||
| `RCLONE_EXCLUDE="*.jpg"` | `--exclude "*.jpg"` |
|
| `RCLONE_EXCLUDE="*.jpg"` | `--exclude "*.jpg"` |
|
||||||
| `RCLONE_EXCLUDE="*.jpg,*.png"` | `--exclude "*.jpg"` `--exclude "*.png"` |
|
| `RCLONE_EXCLUDE="*.jpg,*.png"` | `--exclude "*.jpg"` `--exclude "*.png"` |
|
||||||
| `RCLONE_EXCLUDE='"*.jpg","*.png"'` | `--exclude "*.jpg"` `--exclude "*.png"` |
|
| `RCLONE_EXCLUDE='"*.jpg","*.png"'` | `--exclude "*.jpg"` `--exclude "*.png"` |
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ image](https://securebuild.com/images/rclone) through our partner
|
|||||||
## Release {{% version %}} OS requirements {#osrequirements}
|
## Release {{% version %}} OS requirements {#osrequirements}
|
||||||
|
|
||||||
| OS | Minimum Version |
|
| OS | Minimum Version |
|
||||||
|:-------:|:-------:|
|
| :---: | :---: |
|
||||||
| Linux | Kernel 3.2 |
|
| Linux | Kernel 3.2 |
|
||||||
| macOS | 12 (Monterey) |
|
| macOS | 12 (Monterey) |
|
||||||
| Windows | 10, Server 2016 |
|
| Windows | 10, Server 2016 |
|
||||||
@@ -31,7 +31,7 @@ in the Go Wiki.
|
|||||||
## Release {{% version %}} {#release}
|
## Release {{% version %}} {#release}
|
||||||
|
|
||||||
| Arch-OS | Windows | macOS | Linux | .deb | .rpm | FreeBSD | NetBSD | OpenBSD | Plan9 | Solaris |
|
| Arch-OS | Windows | macOS | Linux | .deb | .rpm | FreeBSD | NetBSD | OpenBSD | Plan9 | Solaris |
|
||||||
|:-------:|:-------:|:-----:|:-----:|:----:|:----:|:-------:|:------:|:-------:|:-----:|:-------:|
|
| :-----: | :-----: | :---: | :---: | :--: | :--: | :-----: | :----: | :-----: | :---: | :-----: |
|
||||||
| Intel/AMD - 64 Bit | {{< download windows amd64 >}} | {{< download osx amd64 >}} | {{< download linux amd64 >}} | {{< download linux amd64 deb >}} | {{< download linux amd64 rpm >}} | {{< download freebsd amd64 >}} | {{< download netbsd amd64 >}} | {{< download openbsd amd64 >}} | {{< download plan9 amd64 >}} | {{< download solaris amd64 >}} |
|
| Intel/AMD - 64 Bit | {{< download windows amd64 >}} | {{< download osx amd64 >}} | {{< download linux amd64 >}} | {{< download linux amd64 deb >}} | {{< download linux amd64 rpm >}} | {{< download freebsd amd64 >}} | {{< download netbsd amd64 >}} | {{< download openbsd amd64 >}} | {{< download plan9 amd64 >}} | {{< download solaris amd64 >}} |
|
||||||
| Intel/AMD - 32 Bit | {{< download windows 386 >}} | - | {{< download linux 386 >}} | {{< download linux 386 deb >}} | {{< download linux 386 rpm >}} | {{< download freebsd 386 >}} | {{< download netbsd 386 >}} | {{< download openbsd 386 >}} | {{< download plan9 386 >}} | - |
|
| Intel/AMD - 32 Bit | {{< download windows 386 >}} | - | {{< download linux 386 >}} | {{< download linux 386 deb >}} | {{< download linux 386 rpm >}} | {{< download freebsd 386 >}} | {{< download netbsd 386 >}} | {{< download openbsd 386 >}} | {{< download plan9 386 >}} | - |
|
||||||
| ARMv5 - 32 Bit NOHF | - | - | {{< download linux arm >}} | {{< download linux arm deb >}} | {{< download linux arm rpm >}} | {{< download freebsd arm >}} | {{< download netbsd arm >}} | - | - | - |
|
| ARMv5 - 32 Bit NOHF | - | - | {{< download linux arm >}} | {{< download linux arm deb >}} | {{< download linux arm rpm >}} | {{< download freebsd arm >}} | {{< download netbsd arm >}} | - | - | - |
|
||||||
@@ -120,7 +120,7 @@ If you would like to download the current version (maybe from a
|
|||||||
script) from a URL which doesn't change then you can use these links.
|
script) from a URL which doesn't change then you can use these links.
|
||||||
|
|
||||||
| Arch-OS | Windows | macOS | Linux | .deb | .rpm | FreeBSD | NetBSD | OpenBSD | Plan9 | Solaris |
|
| Arch-OS | Windows | macOS | Linux | .deb | .rpm | FreeBSD | NetBSD | OpenBSD | Plan9 | Solaris |
|
||||||
|:-------:|:-------:|:-----:|:-----:|:----:|:----:|:-------:|:------:|:-------:|:-----:|:-------:|
|
| :-----: | :-----: | :---: | :---: | :--: | :--: | :-----: | :----: | :-----: | :---: | :-----: |
|
||||||
| Intel/AMD - 64 Bit | {{< cdownload windows amd64 >}} | {{< cdownload osx amd64 >}} | {{< cdownload linux amd64 >}} | {{< cdownload linux amd64 deb >}} | {{< cdownload linux amd64 rpm >}} | {{< cdownload freebsd amd64 >}} | {{< cdownload netbsd amd64 >}} | {{< cdownload openbsd amd64 >}} | {{< cdownload plan9 amd64 >}} | {{< cdownload solaris amd64 >}} |
|
| Intel/AMD - 64 Bit | {{< cdownload windows amd64 >}} | {{< cdownload osx amd64 >}} | {{< cdownload linux amd64 >}} | {{< cdownload linux amd64 deb >}} | {{< cdownload linux amd64 rpm >}} | {{< cdownload freebsd amd64 >}} | {{< cdownload netbsd amd64 >}} | {{< cdownload openbsd amd64 >}} | {{< cdownload plan9 amd64 >}} | {{< cdownload solaris amd64 >}} |
|
||||||
| Intel/AMD - 32 Bit | {{< cdownload windows 386 >}} | - | {{< cdownload linux 386 >}} | {{< cdownload linux 386 deb >}} | {{< cdownload linux 386 rpm >}} | {{< cdownload freebsd 386 >}} | {{< cdownload netbsd 386 >}} | {{< cdownload openbsd 386 >}} | {{< cdownload plan9 386 >}} | - |
|
| Intel/AMD - 32 Bit | {{< cdownload windows 386 >}} | - | {{< cdownload linux 386 >}} | {{< cdownload linux 386 deb >}} | {{< cdownload linux 386 rpm >}} | {{< cdownload freebsd 386 >}} | {{< cdownload netbsd 386 >}} | {{< cdownload openbsd 386 >}} | {{< cdownload plan9 386 >}} | - |
|
||||||
| ARMv5 - 32 Bit NOHF | - | - | {{< cdownload linux arm >}} | {{< cdownload linux arm deb >}} | {{< cdownload linux arm rpm >}} | {{< cdownload freebsd arm >}} | {{< cdownload netbsd arm >}} | - | - | - |
|
| ARMv5 - 32 Bit NOHF | - | - | {{< cdownload linux arm >}} | {{< cdownload linux arm deb >}} | {{< cdownload linux arm rpm >}} | {{< cdownload freebsd arm >}} | {{< cdownload netbsd arm >}} | - | - | - |
|
||||||
@@ -137,7 +137,7 @@ Older downloads can be found at <https://downloads.rclone.org/>
|
|||||||
The latest `rclone` version working for:
|
The latest `rclone` version working for:
|
||||||
|
|
||||||
| OS | Maximum rclone version |
|
| OS | Maximum rclone version |
|
||||||
|:-------:|:-------:|
|
| :---: | :---: |
|
||||||
| Windows 7 | v1.63.1 |
|
| Windows 7 | v1.63.1 |
|
||||||
| Windows Server 2008 | v1.63.1 |
|
| Windows Server 2008 | v1.63.1 |
|
||||||
| Windows Server 2012 | v1.63.1 |
|
| Windows Server 2012 | v1.63.1 |
|
||||||
|
|||||||
@@ -202,28 +202,28 @@ them into regular expressions.
|
|||||||
|
|
||||||
## Filter pattern examples {#examples}
|
## Filter pattern examples {#examples}
|
||||||
|
|
||||||
| Description | Pattern | Matches | Does not match |
|
| Description | Pattern | Matches | Does not match |
|
||||||
| ----------- |-------- | ------- | -------------- |
|
| ----------- | ---------------- | ------------------------------- | ------------------ |
|
||||||
| Wildcard | `*.jpg` | `/file.jpg` | `/file.png` |
|
| Wildcard | `*.jpg` | `/file.jpg` | `/file.png` |
|
||||||
| | | `/dir/file.jpg` | `/dir/file.png` |
|
| | | `/dir/file.jpg` | `/dir/file.png` |
|
||||||
| Rooted | `/*.jpg` | `/file.jpg` | `/file.png` |
|
| Rooted | `/*.jpg` | `/file.jpg` | `/file.png` |
|
||||||
| | | `/file2.jpg` | `/dir/file.jpg` |
|
| | | `/file2.jpg` | `/dir/file.jpg` |
|
||||||
| Alternates | `*.{jpg,png}` | `/file.jpg` | `/file.gif` |
|
| Alternates | `*.{jpg,png}` | `/file.jpg` | `/file.gif` |
|
||||||
| | | `/dir/file.png` | `/dir/file.gif` |
|
| | | `/dir/file.png` | `/dir/file.gif` |
|
||||||
| Path Wildcard | `dir/**` | `/dir/anyfile` | `file.png` |
|
| Path Wildcard | `dir/**` | `/dir/anyfile` | `file.png` |
|
||||||
| | | `/subdir/dir/subsubdir/anyfile` | `/subdir/file.png` |
|
| | | `/subdir/dir/subsubdir/anyfile` | `/subdir/file.png` |
|
||||||
| Any Char | `*.t?t` | `/file.txt` | `/file.qxt` |
|
| Any Char | `*.t?t` | `/file.txt` | `/file.qxt` |
|
||||||
| | | `/dir/file.tzt` | `/dir/file.png` |
|
| | | `/dir/file.tzt` | `/dir/file.png` |
|
||||||
| Range | `*.[a-z]` | `/file.a` | `/file.0` |
|
| Range | `*.[a-z]` | `/file.a` | `/file.0` |
|
||||||
| | | `/dir/file.b` | `/dir/file.1` |
|
| | | `/dir/file.b` | `/dir/file.1` |
|
||||||
| Escape | `*.\?\?\?` | `/file.???` | `/file.abc` |
|
| Escape | `*.\?\?\?` | `/file.???` | `/file.abc` |
|
||||||
| | | `/dir/file.???` | `/dir/file.def` |
|
| | | `/dir/file.???` | `/dir/file.def` |
|
||||||
| Class | `*.\d\d\d` | `/file.012` | `/file.abc` |
|
| Class | `*.\d\d\d` | `/file.012` | `/file.abc` |
|
||||||
| | | `/dir/file.345` | `/dir/file.def` |
|
| | | `/dir/file.345` | `/dir/file.def` |
|
||||||
| Regexp | `*.{{jpe?g}}` | `/file.jpeg` | `/file.png` |
|
| Regexp | `*.{{jpe?g}}` | `/file.jpeg` | `/file.png` |
|
||||||
| | | `/dir/file.jpg` | `/dir/file.jpeeg` |
|
| | | `/dir/file.jpg` | `/dir/file.jpeeg` |
|
||||||
| Rooted Regexp | `/{{.*\.jpe?g}}` | `/file.jpeg` | `/file.png` |
|
| Rooted Regexp | `/{{.*\.jpe?g}}` | `/file.jpeg` | `/file.png` |
|
||||||
| | | `/file.jpg` | `/dir/file.jpg` |
|
| | | `/file.jpg` | `/dir/file.jpg` |
|
||||||
|
|
||||||
## How filter rules are applied to files {#how-filter-rules-work}
|
## How filter rules are applied to files {#how-filter-rules-work}
|
||||||
|
|
||||||
|
|||||||
@@ -285,8 +285,8 @@ rclone v1.49.1
|
|||||||
- go version: go1.12.9
|
- go version: go1.12.9
|
||||||
```
|
```
|
||||||
|
|
||||||
There are a few command line options to consider when starting an rclone Docker container
|
There are a few command line options to consider when starting an rclone Docker
|
||||||
from the rclone image.
|
container from the rclone image.
|
||||||
|
|
||||||
- You need to mount the host rclone config dir at `/config/rclone` into the Docker
|
- You need to mount the host rclone config dir at `/config/rclone` into the Docker
|
||||||
container. Due to the fact that rclone updates tokens inside its config file,
|
container. Due to the fact that rclone updates tokens inside its config file,
|
||||||
@@ -300,8 +300,8 @@ from the rclone image.
|
|||||||
data files reside on the host with a non-root UID:GID, you need to pass these
|
data files reside on the host with a non-root UID:GID, you need to pass these
|
||||||
on the container start command line.
|
on the container start command line.
|
||||||
|
|
||||||
- If you want to access the RC interface (either via the API or the Web UI), it is
|
- If you want to access the RC interface (either via the API or the Web UI), it
|
||||||
required to set the `--rc-addr` to `:5572` in order to connect to it from outside
|
is required to set the `--rc-addr` to `:5572` in order to connect to it from outside
|
||||||
the container. An explanation about why this is necessary can be found in an old
|
the container. An explanation about why this is necessary can be found in an old
|
||||||
[pythonspeed.com](https://web.archive.org/web/20200808071950/https://pythonspeed.com/articles/docker-connection-refused/)
|
[pythonspeed.com](https://web.archive.org/web/20200808071950/https://pythonspeed.com/articles/docker-connection-refused/)
|
||||||
article.
|
article.
|
||||||
@@ -309,9 +309,9 @@ from the rclone image.
|
|||||||
probably set it to listen to localhost only, with `127.0.0.1:5572` as the
|
probably set it to listen to localhost only, with `127.0.0.1:5572` as the
|
||||||
value for `--rc-addr`
|
value for `--rc-addr`
|
||||||
|
|
||||||
- It is possible to use `rclone mount` inside a userspace Docker container, and expose
|
- It is possible to use `rclone mount` inside a userspace Docker container, and
|
||||||
the resulting fuse mount to the host. The exact `docker run` options to do that
|
expose the resulting fuse mount to the host. The exact `docker run` options to
|
||||||
might vary slightly between hosts. See, e.g. the discussion in this
|
do that might vary slightly between hosts. See, e.g. the discussion in this
|
||||||
[thread](https://github.com/moby/moby/issues/9448).
|
[thread](https://github.com/moby/moby/issues/9448).
|
||||||
|
|
||||||
You also need to mount the host `/etc/passwd` and `/etc/group` for fuse to work
|
You also need to mount the host `/etc/passwd` and `/etc/group` for fuse to work
|
||||||
@@ -542,8 +542,8 @@ To override them set the corresponding options (as command-line arguments, or as
|
|||||||
|
|
||||||
After installing and configuring rclone, as described above, you are ready to use
|
After installing and configuring rclone, as described above, you are ready to use
|
||||||
rclone as an interactive command line utility. If your goal is to perform *periodic*
|
rclone as an interactive command line utility. If your goal is to perform *periodic*
|
||||||
operations, such as a regular [sync](https://rclone.org/commands/rclone_sync/), you
|
operations, such as a regular [sync](https://rclone.org/commands/rclone_sync/),
|
||||||
will probably want to configure your rclone command in your operating system's
|
you will probably want to configure your rclone command in your operating system's
|
||||||
scheduler. If you need to expose *service*-like features, such as
|
scheduler. If you need to expose *service*-like features, such as
|
||||||
[remote control](https://rclone.org/rc/), [GUI](https://rclone.org/gui/),
|
[remote control](https://rclone.org/rc/), [GUI](https://rclone.org/gui/),
|
||||||
[serve](https://rclone.org/commands/rclone_serve/) or [mount](https://rclone.org/commands/rclone_mount/),
|
[serve](https://rclone.org/commands/rclone_serve/) or [mount](https://rclone.org/commands/rclone_mount/),
|
||||||
@@ -583,9 +583,9 @@ c:\rclone\rclone.exe sync c:\files remote:/files --no-console --log-file c:\rclo
|
|||||||
|
|
||||||
As mentioned in the [mount](https://rclone.org/commands/rclone_mount/) documentation,
|
As mentioned in the [mount](https://rclone.org/commands/rclone_mount/) documentation,
|
||||||
mounted drives created as Administrator are not visible to other accounts, not even
|
mounted drives created as Administrator are not visible to other accounts, not even
|
||||||
the account that was elevated as Administrator. By running the mount command as the
|
the account that was elevated as Administrator. By running the mount command as
|
||||||
built-in `SYSTEM` user account, it will create drives accessible for everyone on
|
the built-in `SYSTEM` user account, it will create drives accessible for everyone
|
||||||
the system. Both scheduled task and Windows service can be used to achieve this.
|
on the system. Both scheduled task and Windows service can be used to achieve this.
|
||||||
|
|
||||||
NOTE: Remember that when rclone runs as the `SYSTEM` user, the user profile
|
NOTE: Remember that when rclone runs as the `SYSTEM` user, the user profile
|
||||||
that it sees will not be yours. This means that if you normally run rclone with
|
that it sees will not be yours. This means that if you normally run rclone with
|
||||||
@@ -615,8 +615,8 @@ will often give you better results.
|
|||||||
|
|
||||||
#### Start from Task Scheduler
|
#### Start from Task Scheduler
|
||||||
|
|
||||||
Task Scheduler is an administrative tool built into Windows, and it can be used to
|
Task Scheduler is an administrative tool built into Windows, and it can be used
|
||||||
configure rclone to be started automatically in a highly configurable way, e.g.
|
to configure rclone to be started automatically in a highly configurable way, e.g.
|
||||||
periodically on a schedule, on user log on, or at system startup. It can run
|
periodically on a schedule, on user log on, or at system startup. It can run
|
||||||
be configured to run as the current user, or for a mount command that needs to
|
be configured to run as the current user, or for a mount command that needs to
|
||||||
be available to all users it can run as the `SYSTEM` user.
|
be available to all users it can run as the `SYSTEM` user.
|
||||||
@@ -656,18 +656,18 @@ To Windows service running any rclone command, the excellent third-party utility
|
|||||||
[NSSM](http://nssm.cc), the "Non-Sucking Service Manager", can be used.
|
[NSSM](http://nssm.cc), the "Non-Sucking Service Manager", can be used.
|
||||||
It includes some advanced features such as adjusting process priority, defining
|
It includes some advanced features such as adjusting process priority, defining
|
||||||
process environment variables, redirect to file anything written to stdout, and
|
process environment variables, redirect to file anything written to stdout, and
|
||||||
customized response to different exit codes, with a GUI to configure everything from
|
customized response to different exit codes, with a GUI to configure everything
|
||||||
(although it can also be used from command line ).
|
from (although it can also be used from command line ).
|
||||||
|
|
||||||
There are also several other alternatives. To mention one more,
|
There are also several other alternatives. To mention one more,
|
||||||
[WinSW](https://github.com/winsw/winsw), "Windows Service Wrapper", is worth checking
|
[WinSW](https://github.com/winsw/winsw), "Windows Service Wrapper", is worth checking
|
||||||
out. It requires .NET Framework, but it is preinstalled on newer versions of Windows,
|
out. It requires .NET Framework, but it is preinstalled on newer versions of Windows,
|
||||||
and it also provides alternative standalone distributions which includes necessary
|
and it also provides alternative standalone distributions which includes necessary
|
||||||
runtime (.NET 5). WinSW is a command-line only utility, where you have to manually
|
runtime (.NET 5). WinSW is a command-line only utility, where you have to manually
|
||||||
create an XML file with service configuration. This may be a drawback for some, but
|
create an XML file with service configuration. This may be a drawback for some,
|
||||||
it can also be an advantage as it is easy to back up and reuse the configuration
|
but it can also be an advantage as it is easy to back up and reuse the configuration
|
||||||
settings, without having go through manual steps in a GUI. One thing to note is that
|
settings, without having go through manual steps in a GUI. One thing to note is
|
||||||
by default it does not restart the service on error, one have to explicit enable
|
that by default it does not restart the service on error, one have to explicit enable
|
||||||
this in the configuration file (via the "onfailure" parameter).
|
this in the configuration file (via the "onfailure" parameter).
|
||||||
|
|
||||||
### Autostart on Linux
|
### Autostart on Linux
|
||||||
@@ -676,8 +676,8 @@ this in the configuration file (via the "onfailure" parameter).
|
|||||||
|
|
||||||
To always run rclone in background, relevant for mount commands etc,
|
To always run rclone in background, relevant for mount commands etc,
|
||||||
you can use systemd to set up rclone as a system or user service. Running as a
|
you can use systemd to set up rclone as a system or user service. Running as a
|
||||||
system service ensures that it is run at startup even if the user it is running as
|
system service ensures that it is run at startup even if the user it is running
|
||||||
has no active session. Running rclone as a user service ensures that it only
|
as has no active session. Running rclone as a user service ensures that it only
|
||||||
starts after the configured user has logged into the system.
|
starts after the configured user has logged into the system.
|
||||||
|
|
||||||
#### Run periodically from cron
|
#### Run periodically from cron
|
||||||
|
|||||||
@@ -14,62 +14,62 @@ show through.
|
|||||||
|
|
||||||
Here is an overview of the major features of each cloud storage system.
|
Here is an overview of the major features of each cloud storage system.
|
||||||
|
|
||||||
| Name | Hash | ModTime | Case Insensitive | Duplicate Files | MIME Type | Metadata |
|
| Name | Hash | ModTime | Case Insensitive | Duplicate Files | MIME Type | Metadata |
|
||||||
| ---------------------------- |:-----------------:|:-------:|:----------------:|:---------------:|:---------:|:--------:|
|
| ----------------------------- | :---------------: | :-----: | :--------------: | :-------------: | :-------: | :------: |
|
||||||
| 1Fichier | Whirlpool | - | No | Yes | R | - |
|
| 1Fichier | Whirlpool | - | No | Yes | R | - |
|
||||||
| Akamai Netstorage | MD5, SHA256 | R/W | No | No | R | - |
|
| Akamai Netstorage | MD5, SHA256 | R/W | No | No | R | - |
|
||||||
| Amazon S3 (or S3 compatible) | MD5 | R/W | No | No | R/W | RWU |
|
| Amazon S3 (or S3 compatible) | MD5 | R/W | No | No | R/W | RWU |
|
||||||
| Backblaze B2 | SHA1 | R/W | No | No | R/W | - |
|
| Backblaze B2 | SHA1 | R/W | No | No | R/W | - |
|
||||||
| Box | SHA1 | R/W | Yes | No | - | - |
|
| Box | SHA1 | R/W | Yes | No | - | - |
|
||||||
| Citrix ShareFile | MD5 | R/W | Yes | No | - | - |
|
| Citrix ShareFile | MD5 | R/W | Yes | No | - | - |
|
||||||
| Cloudinary | MD5 | R | No | Yes | - | - |
|
| Cloudinary | MD5 | R | No | Yes | - | - |
|
||||||
| Dropbox | DBHASH ¹ | R | Yes | No | - | - |
|
| Dropbox | DBHASH ¹ | R | Yes | No | - | - |
|
||||||
| Enterprise File Fabric | - | R/W | Yes | No | R/W | - |
|
| Enterprise File Fabric | - | R/W | Yes | No | R/W | - |
|
||||||
| FileLu Cloud Storage | MD5 | R/W | No | Yes | R | - |
|
| FileLu Cloud Storage | MD5 | R/W | No | Yes | R | - |
|
||||||
| Files.com | MD5, CRC32 | DR/W | Yes | No | R | - |
|
| Files.com | MD5, CRC32 | DR/W | Yes | No | R | - |
|
||||||
| FTP | - | R/W ¹⁰ | No | No | - | - |
|
| FTP | - | R/W ¹⁰ | No | No | - | - |
|
||||||
| Gofile | MD5 | DR/W | No | Yes | R | - |
|
| Gofile | MD5 | DR/W | No | Yes | R | - |
|
||||||
| Google Cloud Storage | MD5 | R/W | No | No | R/W | - |
|
| Google Cloud Storage | MD5 | R/W | No | No | R/W | - |
|
||||||
| Google Drive | MD5, SHA1, SHA256 | DR/W | No | Yes | R/W | DRWU |
|
| Google Drive | MD5, SHA1, SHA256 | DR/W | No | Yes | R/W | DRWU |
|
||||||
| Google Photos | - | - | No | Yes | R | - |
|
| Google Photos | - | - | No | Yes | R | - |
|
||||||
| HDFS | - | R/W | No | No | - | - |
|
| HDFS | - | R/W | No | No | - | - |
|
||||||
| HiDrive | HiDrive ¹² | R/W | No | No | - | - |
|
| HiDrive | HiDrive ¹² | R/W | No | No | - | - |
|
||||||
| HTTP | - | R | No | No | R | R |
|
| HTTP | - | R | No | No | R | R |
|
||||||
| iCloud Drive | - | R | No | No | - | - |
|
| iCloud Drive | - | R | No | No | - | - |
|
||||||
| Internet Archive | MD5, SHA1, CRC32 | R/W ¹¹ | No | No | - | RWU |
|
| Internet Archive | MD5, SHA1, CRC32 | R/W ¹¹ | No | No | - | RWU |
|
||||||
| Jottacloud | MD5 | R/W | Yes | No | R | RW |
|
| Jottacloud | MD5 | R/W | Yes | No | R | RW |
|
||||||
| Koofr | MD5 | - | Yes | No | - | - |
|
| Koofr | MD5 | - | Yes | No | - | - |
|
||||||
| Linkbox | - | R | No | No | - | - |
|
| Linkbox | - | R | No | No | - | - |
|
||||||
| Mail.ru Cloud | Mailru ⁶ | R/W | Yes | No | - | - |
|
| Mail.ru Cloud | Mailru ⁶ | R/W | Yes | No | - | - |
|
||||||
| Mega | - | - | No | Yes | - | - |
|
| Mega | - | - | No | Yes | - | - |
|
||||||
| Memory | MD5 | R/W | No | No | - | - |
|
| Memory | MD5 | R/W | No | No | - | - |
|
||||||
| Microsoft Azure Blob Storage | MD5 | R/W | No | No | R/W | - |
|
| Microsoft Azure Blob Storage | MD5 | R/W | No | No | R/W | - |
|
||||||
| Microsoft Azure Files Storage | MD5 | R/W | Yes | No | R/W | - |
|
| Microsoft Azure Files Storage | MD5 | R/W | Yes | No | R/W | - |
|
||||||
| Microsoft OneDrive | QuickXorHash ⁵ | DR/W | Yes | No | R | DRW |
|
| Microsoft OneDrive | QuickXorHash ⁵ | DR/W | Yes | No | R | DRW |
|
||||||
| OpenDrive | MD5 | R/W | Yes | Partial ⁸ | - | - |
|
| OpenDrive | MD5 | R/W | Yes | Partial ⁸ | - | - |
|
||||||
| OpenStack Swift | MD5 | R/W | No | No | R/W | - |
|
| OpenStack Swift | MD5 | R/W | No | No | R/W | - |
|
||||||
| Oracle Object Storage | MD5 | R/W | No | No | R/W | RU |
|
| Oracle Object Storage | MD5 | R/W | No | No | R/W | RU |
|
||||||
| pCloud | MD5, SHA1 ⁷ | R/W | No | No | W | - |
|
| pCloud | MD5, SHA1 ⁷ | R/W | No | No | W | - |
|
||||||
| PikPak | MD5 | R | No | No | R | - |
|
| PikPak | MD5 | R | No | No | R | - |
|
||||||
| Pixeldrain | SHA256 | R/W | No | No | R | RW |
|
| Pixeldrain | SHA256 | R/W | No | No | R | RW |
|
||||||
| premiumize.me | - | - | Yes | No | R | - |
|
| premiumize.me | - | - | Yes | No | R | - |
|
||||||
| put.io | CRC-32 | R/W | No | Yes | R | - |
|
| put.io | CRC-32 | R/W | No | Yes | R | - |
|
||||||
| Proton Drive | SHA1 | R/W | No | No | R | - |
|
| Proton Drive | SHA1 | R/W | No | No | R | - |
|
||||||
| QingStor | MD5 | - ⁹ | No | No | R/W | - |
|
| QingStor | MD5 | - ⁹ | No | No | R/W | - |
|
||||||
| Quatrix by Maytech | - | R/W | No | No | - | - |
|
| Quatrix by Maytech | - | R/W | No | No | - | - |
|
||||||
| Seafile | - | - | No | No | - | - |
|
| Seafile | - | - | No | No | - | - |
|
||||||
| SFTP | MD5, SHA1 ² | DR/W | Depends | No | - | - |
|
| SFTP | MD5, SHA1 ² | DR/W | Depends | No | - | - |
|
||||||
| Shade | - | - | Yes | No | - | - |
|
| Shade | - | - | Yes | No | - | - |
|
||||||
| Sia | - | - | No | No | - | - |
|
| Sia | - | - | No | No | - | - |
|
||||||
| SMB | - | R/W | Yes | No | - | - |
|
| SMB | - | R/W | Yes | No | - | - |
|
||||||
| SugarSync | - | - | No | No | - | - |
|
| SugarSync | - | - | No | No | - | - |
|
||||||
| Storj | - | R | No | No | - | - |
|
| Storj | - | R | No | No | - | - |
|
||||||
| Uloz.to | MD5, SHA256 ¹³ | - | No | Yes | - | - |
|
| Uloz.to | MD5, SHA256 ¹³ | - | No | Yes | - | - |
|
||||||
| Uptobox | - | - | No | Yes | - | - |
|
| Uptobox | - | - | No | Yes | - | - |
|
||||||
| WebDAV | MD5, SHA1 ³ | R ⁴ | Depends | No | - | - |
|
| WebDAV | MD5, SHA1 ³ | R ⁴ | Depends | No | - | - |
|
||||||
| Yandex Disk | MD5 | R/W | No | No | R | - |
|
| Yandex Disk | MD5 | R/W | No | No | R | - |
|
||||||
| Zoho WorkDrive | - | - | No | No | - | - |
|
| Zoho WorkDrive | - | - | No | No | - | - |
|
||||||
| The local filesystem | All | DR/W | Depends | No | - | DRWU |
|
| The local filesystem | All | DR/W | Depends | No | - | DRWU |
|
||||||
|
|
||||||
¹ Dropbox supports [its own custom
|
¹ Dropbox supports [its own custom
|
||||||
hash](https://www.dropbox.com/developers/reference/content-hash).
|
hash](https://www.dropbox.com/developers/reference/content-hash).
|
||||||
@@ -136,7 +136,7 @@ size by default, though can be configured to check the file hash
|
|||||||
change the timestamp of an existing file without having to re-upload it.
|
change the timestamp of an existing file without having to re-upload it.
|
||||||
|
|
||||||
| Key | Explanation |
|
| Key | Explanation |
|
||||||
|-----|-------------|
|
| --- | ----------- |
|
||||||
| `-` | ModTimes not supported - times likely the upload time |
|
| `-` | ModTimes not supported - times likely the upload time |
|
||||||
| `R` | ModTimes supported on files but can't be changed without re-upload |
|
| `R` | ModTimes supported on files but can't be changed without re-upload |
|
||||||
| `R/W` | Read and Write ModTimes fully supported on files |
|
| `R/W` | Read and Write ModTimes fully supported on files |
|
||||||
@@ -283,8 +283,8 @@ will be escaped with the `‛` character to avoid ambiguous file names.
|
|||||||
Each cloud storage backend can use a different set of characters,
|
Each cloud storage backend can use a different set of characters,
|
||||||
which will be specified in the documentation for each backend.
|
which will be specified in the documentation for each backend.
|
||||||
|
|
||||||
| Character | Value | Replacement |
|
| Character | Value | Replacement |
|
||||||
| --------- |:-----:|:-----------:|
|
| --------- | :---: | :---------- :|
|
||||||
| NUL | 0x00 | ␀ |
|
| NUL | 0x00 | ␀ |
|
||||||
| SOH | 0x01 | ␁ |
|
| SOH | 0x01 | ␁ |
|
||||||
| STX | 0x02 | ␂ |
|
| STX | 0x02 | ␂ |
|
||||||
@@ -324,9 +324,9 @@ The default encoding will also encode these file names as they are
|
|||||||
problematic with many cloud storage systems.
|
problematic with many cloud storage systems.
|
||||||
|
|
||||||
| File name | Replacement |
|
| File name | Replacement |
|
||||||
| --------- |:-----------:|
|
| --------- | :--------- :|
|
||||||
| . | . |
|
| . | . |
|
||||||
| .. | .. |
|
| .. | .. |
|
||||||
|
|
||||||
#### Invalid UTF-8 bytes {#invalid-utf8}
|
#### Invalid UTF-8 bytes {#invalid-utf8}
|
||||||
|
|
||||||
@@ -366,8 +366,8 @@ list of all possible values by passing an invalid value to this
|
|||||||
flag, e.g. `--local-encoding "help"`. The command `rclone help flags encoding`
|
flag, e.g. `--local-encoding "help"`. The command `rclone help flags encoding`
|
||||||
will show you the defaults for the backends.
|
will show you the defaults for the backends.
|
||||||
|
|
||||||
| Encoding | Characters | Encoded as |
|
| Encoding | Characters | Encoded as |
|
||||||
| --------- | ---------- | ---------- |
|
| -------- | ---------- | ---------- |
|
||||||
| Asterisk | `*` | `*` |
|
| Asterisk | `*` | `*` |
|
||||||
| BackQuote | `` ` `` | ``` |
|
| BackQuote | `` ` `` | ``` |
|
||||||
| BackSlash | `\` | `\` |
|
| BackSlash | `\` | `\` |
|
||||||
@@ -492,12 +492,12 @@ that backend) and/or user metadata (general purpose metadata).
|
|||||||
The levels of metadata support are
|
The levels of metadata support are
|
||||||
|
|
||||||
| Key | Explanation |
|
| Key | Explanation |
|
||||||
|-----|-------------|
|
| --- | ----------- |
|
||||||
| `R` | Read only System Metadata on files only|
|
| `R` | Read only System Metadata on files only |
|
||||||
| `RW` | Read and write System Metadata on files only|
|
| `RW` | Read and write System Metadata on files only |
|
||||||
| `RWU` | Read and write System Metadata and read and write User Metadata on files only|
|
| `RWU` | Read and write System Metadata and read and write User Metadata on files only |
|
||||||
| `DR` | Read only System Metadata on files and directories |
|
| `DR` | Read only System Metadata on files and directories |
|
||||||
| `DRW` | Read and write System Metadata on files and directories|
|
| `DRW` | Read and write System Metadata on files and directories |
|
||||||
| `DRWU` | Read and write System Metadata and read and write User Metadata on files and directories |
|
| `DRWU` | Read and write System Metadata and read and write User Metadata on files and directories |
|
||||||
|
|
||||||
See [the metadata docs](/docs/#metadata) for more info.
|
See [the metadata docs](/docs/#metadata) for more info.
|
||||||
@@ -507,60 +507,60 @@ See [the metadata docs](/docs/#metadata) for more info.
|
|||||||
All rclone remotes support a base command set. Other features depend
|
All rclone remotes support a base command set. Other features depend
|
||||||
upon backend-specific capabilities.
|
upon backend-specific capabilities.
|
||||||
|
|
||||||
| Name | Purge | Copy | Move | DirMove | CleanUp | ListR | StreamUpload | MultithreadUpload | LinkSharing | About | EmptyDir |
|
| Name | Purge | Copy | Move | DirMove | CleanUp | ListR | StreamUpload | MultithreadUpload | LinkSharing | About | EmptyDir |
|
||||||
| ---------------------------- |:-----:|:----:|:----:|:-------:|:-------:|:-----:|:------------:|:------------------|:------------:|:-----:|:--------:|
|
| ----------------------------- | :---: | :--: | :--: | :-----: | :-----: | :---: | :----------: | :-----------------| :----------: | :---: | :------: |
|
||||||
| 1Fichier | No | Yes | Yes | No | No | No | No | No | Yes | No | Yes |
|
| 1Fichier | No | Yes | Yes | No | No | No | No | No | Yes | No | Yes |
|
||||||
| Akamai Netstorage | Yes | No | No | No | No | Yes | Yes | No | No | No | Yes |
|
| Akamai Netstorage | Yes | No | No | No | No | Yes | Yes | No | No | No | Yes |
|
||||||
| Amazon S3 (or S3 compatible) | No | Yes | No | No | Yes | Yes | Yes | Yes | Yes | No | No |
|
| Amazon S3 (or S3 compatible) | No | Yes | No | No | Yes | Yes | Yes | Yes | Yes | No | No |
|
||||||
| Backblaze B2 | No | Yes | No | No | Yes | Yes | Yes | Yes | Yes | No | No |
|
| Backblaze B2 | No | Yes | No | No | Yes | Yes | Yes | Yes | Yes | No | No |
|
||||||
| Box | Yes | Yes | Yes | Yes | Yes | No | Yes | No | Yes | Yes | Yes |
|
| Box | Yes | Yes | Yes | Yes | Yes | No | Yes | No | Yes | Yes | Yes |
|
||||||
| Citrix ShareFile | Yes | Yes | Yes | Yes | No | No | No | No | No | No | Yes |
|
| Citrix ShareFile | Yes | Yes | Yes | Yes | No | No | No | No | No | No | Yes |
|
||||||
| Dropbox | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
| Dropbox | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
||||||
| Cloudinary | No | No | No | No | No | No | Yes | No | No | No | No |
|
| Cloudinary | No | No | No | No | No | No | Yes | No | No | No | No |
|
||||||
| Enterprise File Fabric | Yes | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes |
|
| Enterprise File Fabric | Yes | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes |
|
||||||
| Files.com | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | No | Yes |
|
| Files.com | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | No | Yes |
|
||||||
| FTP | No | No | Yes | Yes | No | No | Yes | No | No | No | Yes |
|
| FTP | No | No | Yes | Yes | No | No | Yes | No | No | No | Yes |
|
||||||
| Gofile | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
| Gofile | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
||||||
| Google Cloud Storage | Yes | Yes | No | No | No | No | Yes | No | No | No | No |
|
| Google Cloud Storage | Yes | Yes | No | No | No | No | Yes | No | No | No | No |
|
||||||
| Google Drive | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | Yes |
|
| Google Drive | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | Yes |
|
||||||
| Google Photos | No | No | No | No | No | No | No | No | No | No | No |
|
| Google Photos | No | No | No | No | No | No | No | No | No | No | No |
|
||||||
| HDFS | Yes | No | Yes | Yes | No | No | Yes | No | No | Yes | Yes |
|
| HDFS | Yes | No | Yes | Yes | No | No | Yes | No | No | Yes | Yes |
|
||||||
| HiDrive | Yes | Yes | Yes | Yes | No | No | Yes | No | No | No | Yes |
|
| HiDrive | Yes | Yes | Yes | Yes | No | No | Yes | No | No | No | Yes |
|
||||||
| HTTP | No | No | No | No | No | No | No | No | No | No | Yes |
|
| HTTP | No | No | No | No | No | No | No | No | No | No | Yes |
|
||||||
| iCloud Drive | Yes | Yes | Yes | Yes | No | No | No | No | No | No | Yes |
|
| iCloud Drive | Yes | Yes | Yes | Yes | No | No | No | No | No | No | Yes |
|
||||||
| ImageKit | Yes | No | Yes | No | No | No | No | No | No | No | Yes |
|
| ImageKit | Yes | No | Yes | No | No | No | No | No | No | No | Yes |
|
||||||
| Internet Archive | No | Yes | No | No | Yes | Yes | No | No | Yes | Yes | No |
|
| Internet Archive | No | Yes | No | No | Yes | Yes | No | No | Yes | Yes | No |
|
||||||
| Jottacloud | Yes | Yes | Yes | Yes | Yes | Yes | No | No | Yes | Yes | Yes |
|
| Jottacloud | Yes | Yes | Yes | Yes | Yes | Yes | No | No | Yes | Yes | Yes |
|
||||||
| Koofr | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
| Koofr | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
||||||
| Mail.ru Cloud | Yes | Yes | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
| Mail.ru Cloud | Yes | Yes | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
||||||
| Mega | Yes | No | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
| Mega | Yes | No | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
||||||
| Memory | No | Yes | No | No | No | Yes | Yes | No | No | No | No |
|
| Memory | No | Yes | No | No | No | Yes | Yes | No | No | No | No |
|
||||||
| Microsoft Azure Blob Storage | Yes | Yes | No | No | No | Yes | Yes | Yes | No | No | No |
|
| Microsoft Azure Blob Storage | Yes | Yes | No | No | No | Yes | Yes | Yes | No | No | No |
|
||||||
| Microsoft Azure Files Storage | No | Yes | Yes | Yes | No | No | Yes | Yes | No | Yes | Yes |
|
| Microsoft Azure Files Storage | No | Yes | Yes | Yes | No | No | Yes | Yes | No | Yes | Yes |
|
||||||
| Microsoft OneDrive | Yes | Yes | Yes | Yes | Yes | Yes ⁵ | No | No | Yes | Yes | Yes |
|
| Microsoft OneDrive | Yes | Yes | Yes | Yes | Yes | Yes ⁵ | No | No | Yes | Yes | Yes |
|
||||||
| OpenDrive | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
| OpenDrive | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
||||||
| OpenStack Swift | Yes ¹ | Yes | No | No | No | Yes | Yes | No | No | Yes | No |
|
| OpenStack Swift | Yes ¹ | Yes | No | No | No | Yes | Yes | No | No | Yes | No |
|
||||||
| Oracle Object Storage | No | Yes | No | No | Yes | Yes | Yes | Yes | No | No | No |
|
| Oracle Object Storage | No | Yes | No | No | Yes | Yes | Yes | Yes | No | No | No |
|
||||||
| pCloud | Yes | Yes | Yes | Yes | Yes | Yes | No | No | Yes | Yes | Yes |
|
| pCloud | Yes | Yes | Yes | Yes | Yes | Yes | No | No | Yes | Yes | Yes |
|
||||||
| PikPak | Yes | Yes | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
| PikPak | Yes | Yes | Yes | Yes | Yes | No | No | No | Yes | Yes | Yes |
|
||||||
| Pixeldrain | Yes | No | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
| Pixeldrain | Yes | No | Yes | Yes | No | No | Yes | No | Yes | Yes | Yes |
|
||||||
| premiumize.me | Yes | No | Yes | Yes | No | No | No | No | Yes | Yes | Yes |
|
| premiumize.me | Yes | No | Yes | Yes | No | No | No | No | Yes | Yes | Yes |
|
||||||
| put.io | Yes | No | Yes | Yes | Yes | No | Yes | No | No | Yes | Yes |
|
| put.io | Yes | No | Yes | Yes | Yes | No | Yes | No | No | Yes | Yes |
|
||||||
| Proton Drive | Yes | No | Yes | Yes | Yes | No | No | No | No | Yes | Yes |
|
| Proton Drive | Yes | No | Yes | Yes | Yes | No | No | No | No | Yes | Yes |
|
||||||
| QingStor | No | Yes | No | No | Yes | Yes | No | No | No | No | No |
|
| QingStor | No | Yes | No | No | Yes | Yes | No | No | No | No | No |
|
||||||
| Quatrix by Maytech | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
| Quatrix by Maytech | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
||||||
| Seafile | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | Yes |
|
| Seafile | Yes | Yes | Yes | Yes | Yes | Yes | Yes | No | Yes | Yes | Yes |
|
||||||
| SFTP | No | Yes ⁴| Yes | Yes | No | No | Yes | No | No | Yes | Yes |
|
| SFTP | No | Yes ⁴| Yes | Yes | No | No | Yes | No | No | Yes | Yes |
|
||||||
| Sia | No | No | No | No | No | No | Yes | No | No | No | Yes |
|
| Sia | No | No | No | No | No | No | Yes | No | No | No | Yes |
|
||||||
| SMB | No | No | Yes | Yes | No | No | Yes | Yes | No | No | Yes |
|
| SMB | No | No | Yes | Yes | No | No | Yes | Yes | No | No | Yes |
|
||||||
| SugarSync | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | No | Yes |
|
| SugarSync | Yes | Yes | Yes | Yes | No | No | Yes | No | Yes | No | Yes |
|
||||||
| Storj | Yes ² | Yes | Yes | No | No | Yes | Yes | No | Yes | No | No |
|
| Storj | Yes ² | Yes | Yes | No | No | Yes | Yes | No | Yes | No | No |
|
||||||
| Uloz.to | No | No | Yes | Yes | No | No | No | No | No | No | Yes |
|
| Uloz.to | No | No | Yes | Yes | No | No | No | No | No | No | Yes |
|
||||||
| Uptobox | No | Yes | Yes | Yes | No | No | No | No | No | No | No |
|
| Uptobox | No | Yes | Yes | Yes | No | No | No | No | No | No | No |
|
||||||
| WebDAV | Yes | Yes | Yes | Yes | No | No | Yes ³ | No | No | Yes | Yes |
|
| WebDAV | Yes | Yes | Yes | Yes | No | No | Yes ³ | No | No | Yes | Yes |
|
||||||
| Yandex Disk | Yes | Yes | Yes | Yes | Yes | No | Yes | No | Yes | Yes | Yes |
|
| Yandex Disk | Yes | Yes | Yes | Yes | Yes | No | Yes | No | Yes | Yes | Yes |
|
||||||
| Zoho WorkDrive | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
| Zoho WorkDrive | Yes | Yes | Yes | Yes | No | No | No | No | No | Yes | Yes |
|
||||||
| The local filesystem | No | No | Yes | Yes | No | No | Yes | Yes | No | Yes | Yes |
|
| The local filesystem | No | No | Yes | Yes | No | No | Yes | Yes | No | Yes | Yes |
|
||||||
|
|
||||||
¹ Note Swift implements this in order to delete directory markers but
|
¹ Note Swift implements this in order to delete directory markers but
|
||||||
it doesn't actually have a quicker way of deleting files other than
|
it doesn't actually have a quicker way of deleting files other than
|
||||||
|
|||||||
@@ -173,6 +173,31 @@ So if the folder you want rclone to use your is "My Music/", then use the return
|
|||||||
id from ```rclone lsf``` command (ex. `dxxxxxxxx2`) as the `root_folder_id` variable
|
id from ```rclone lsf``` command (ex. `dxxxxxxxx2`) as the `root_folder_id` variable
|
||||||
value in the config file.
|
value in the config file.
|
||||||
|
|
||||||
|
### Change notifications and mounts
|
||||||
|
|
||||||
|
The pCloud backend supports real‑time updates for rclone mounts via change
|
||||||
|
notifications. rclone uses pCloud’s diff long‑polling API to detect changes and
|
||||||
|
will automatically refresh directory listings in the mounted filesystem when
|
||||||
|
changes occur.
|
||||||
|
|
||||||
|
Notes and behavior:
|
||||||
|
|
||||||
|
- Works automatically when using `rclone mount` and requires no additional
|
||||||
|
configuration.
|
||||||
|
- Notifications are directory‑scoped: when rclone detects a change, it refreshes
|
||||||
|
the affected directory so new/removed/renamed files become visible promptly.
|
||||||
|
- Updates are near real‑time. The backend uses a long‑poll with short fallback
|
||||||
|
polling intervals, so you should see changes appear quickly without manual
|
||||||
|
refreshes.
|
||||||
|
|
||||||
|
If you want to debug or verify notifications, you can use the helper command:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
rclone test changenotify remote:
|
||||||
|
```
|
||||||
|
|
||||||
|
This will log incoming change notifications for the given remote.
|
||||||
|
|
||||||
<!-- autogenerated options start - DO NOT EDIT - instead edit fs.RegInfo in backend/pcloud/pcloud.go and run make backenddocs to verify --> <!-- markdownlint-disable-line line-length -->
|
<!-- autogenerated options start - DO NOT EDIT - instead edit fs.RegInfo in backend/pcloud/pcloud.go and run make backenddocs to verify --> <!-- markdownlint-disable-line line-length -->
|
||||||
### Standard options
|
### Standard options
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user