gclone

command module
v1.61.1-mod2.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2023 License: MIT Imports: 6 Imported by: 0

README

gclone


A modified version of the rclone created by donwa/gclone updated by Thoxy
Provide dynamic replacement sa file support for google drive operation

Installation

Instructions

1. service_account_file_path Configuration

add service_account_file_path Configuration.For dynamic replacement service_account_file(sa file). Replace configuration when rateLimitExceeded error occurs rclone.conf example:

[drive]
type = drive
scope = drive
service_account_file_path = /path/to/accounts/folder
root_folder_id = TD ID or Folder ID

/path/to/accounts/folder Folder contains multiple access and edit permissions service account file(.json)*.

2. Support incoming id

If the original rclone is across team disks or shared folders, multiple configuration drive letters are required for operation. gclone supports incoming id operation

gclone copy gc:{folde_id1} gc:{folde_id2}  -P --stats=5s --ignore-existing --drive-server-side-across-configs --drive-acknowledge-abuse --drive-keep-revision-forever --tpslimit=6 --tpslimit-burst=8 --transfers=5 --checkers=5 --drive-chunk-size 1024M

folde_id1 can be:Common directory, shared directory, team disk.

gclone copy gc:{folde_id1} gc:{folde_id2}/media/  -P --stats=5s --ignore-existing --drive-server-side-across-configs --drive-acknowledge-abuse --drive-keep-revision-forever --tpslimit=6 --tpslimit-burst=8 --transfers=5 --checkers=5 --drive-chunk-size 1024M
gclone copy gc:{share_fiel_id} gc:{folde_id2}  -P --stats=5s --ignore-existing --drive-server-side-across-configs --drive-acknowledge-abuse --drive-keep-revision-forever --tpslimit=6 --tpslimit-burst=8 --transfers=5 --checkers=5 --drive-chunk-size 1024M

Mount

With Service (best method)

First modify the paths to mach yours in the gclone.service.sample and copy it to /etc/systemd/system/gclone.service

Then put this in your console to reload the systemctl services list

sudo systemctl daemon-reload

Then you can use it like all other service.

sudo systemctl start gclone
sudo systemctl enable --now gclone
sudo systemctl stop gclone
sudo systemctl restart gclone
With Docker

Put your config file in /home/user/.gclone (gclone.conf and accounts folder)

docker-compose.yml:

services:
  gclone:
    devices:
      - "/dev/fuse"
    container_name: gclone
    cap_add:
      - "SYS_ADMIN"
    build: https://gitea.s1.thoxy.xyz/thoxy/gclone.git
    environment:
      - 'MOUNTSOURCE=encrypted:'
      - 'MOUNTDESTINATION=/mnt/drive'
    volumes:
      - /mnt/drive:/mnt/drive:shared
      - /home/user/.gclone/:/gclone/config

(I have tested many config and seems to be the most optimized for plex use)

With gclone (not persistant)

Just use the gclone mount command

/usr/bin/gclone --config /gclone/config/gclone.conf mount MOUNTSOURCE MOUNTDESTINATION MOUNTCOMMAND --allow-non-empty --allow-other --log-level INFO --log-file /gclone/logs/rclonecache.log --poll-interval 15s --buffer-size 128M --cache-dir /gclone/cache --vfs-read-chunk-size 1024M --vfs-read-chunk-size-limit off --dir-cache-time 72h --drive-chunk-size 64M

Warning

It is recommended to encrypt the drive. To make it you can follow this guides :

Credit

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
backend
all
Package all imports all the backends
Package all imports all the backends
drive
Package drive interfaces with the Google Drive object storage system
Package drive interfaces with the Google Drive object storage system
cmd
copy
Package copy provides the copy command.
Package copy provides the copy command.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL