Directory artaigil
a ’cleachdadh an-dràsta Rclone Nuair a bhios tu a’ gluasad fhaidhlichean gu OneDrive, dh’ fhaodadh gum bi duilgheadasan agad leithid astar slaodach agus dì-cheangal ...
Carson a tha Rclone slaodach gus ceangal ri Onedrive?
Is e am bun-adhbhar cuingealachadh API OneDrive a bhrosnachadh, agus tha an API bunaiteach Rclone togte air a chleachdadh le grunn dhaoine aig an aon àm, agus mar sin tha na duilgheadasan sin a’ fàs nas follaisiche ...
Faodaidh cleachdadh an API prìobhaideach fèin-thogte gus ceangal ri OneDrive na suidheachaidhean sin a leasachadh gu mòr, agus airson an tionndadh deuchainn leasaiche Office 365 E5 trì-mìosan, bidh cothrom aig Rclone ùrachadh bho àm gu àm, seach a bhith a’ brùthadh an API a dh’aona ghnothach, a tha e nas sàbhailte agus nas seasmhaiche.
A bharrachd air an sin, faodar APIan fèin-thogte a chleachdadh le cunntasan eile agus tagraidhean eile.
Mas e API fèin-thogte le Google Drive a th’ ann, thoir sùil air an oideachadh seo ▼
Rclone connect Onedrive deuchainn astar
Is e a’ chiad fhear deuchainn a dhèanamh air astar cleachdadh API bunaiteach Rclone gus ceangal ri Onedrive▼
Tha an tè mu dheireadh na dheuchainn le netizens gus an API Microsoft a chuir iad a-steach a chleachdadh gus ceangal ri Onedrive ▼
- Chithear gu soilleir gu bheil an eadar-dhealachadh astair còrr is 10 tursan.
Mar a chruthaicheas tu API diosc lìonra Microsoft Onedrive?
Mar a gheibh thu ID teachdaiche agus dìomhaireachd teachdaiche ann an Ionad Riaghlaidh Microsoft Azure, feuch an cliog thu air a’ cheangal gu h-ìosal gus faicinn mar a chruthaicheas tu API diosc lìonra Microsoft Onedrive ▼
Gheibh RClone comharra
Luchdaich sìos Rclone air a ’choimpiutair ionadail agad ▼
Gabh Windows mar eisimpleir, rachaibh chun phasgan far a bheil rclone.exe suidhichte às deidh dì-dhùmhlachadh, cuir a-steach cmd ann am bàr seòlaidh an rannsachair agus brùth Enter gus an àithne fhosgladh gu sgiobalta san t-slighe gnàthach.
Cuir an àite san òrdugh a leanasClient_ID
,Client_secret
agus cuir an gnìomh ▼
rclone authorize "onedrive" "Client_ID" "Client_secret"
- Nochdaidh brobhsair an ath rud, ag iarraidh ort logadh a-steach don chunntas agad gus a cheadachadh.
Às deidh cead, nochdaidh an teachdaireachd a leanas ann an uinneag an àithne gu sgiobalta:
If your browser doesn't open automatically go to the following link: http://127.0.0.1:53682/auth Log in and authorize rclone for access Waiting for code... Got code Paste the following into your remote machine ---> {"access_token":"xxxxxxxxxxxxxxxxxx","expiry":"2024-05-15T21:18:39.5036298+08:00"} <---End paste
{"access_token":"xxxxxxxxxxxxxxxxxx","expiry":"2024-05-15T21:18:39.5036298+08:00"}
Is e an t-susbaint gu lèir seo (a’ gabhail a-steach na camagan) an comharra, dèan lethbhreac agus sàbhail.
Rclone ceangal ri OneDrive
SSH cuir a-steach an àithne a leanas ▼
rclone config
Nochdaidh am fiosrachadh a leanas, thoir sùil air an stiùireadh a leanas airson obrachadh ▼
- Nota:Leis gun tèid RCLONE ùrachadh bho àm gu àm, nuair a chì thu an oideachadh seo, faodaidh na roghainnean clàr atharrachadh beagan, ach chan atharraich am beachd coitcheann Na smaoinich mu bhith a’ dèanamh lethbhreac den obair.
$ rclone config e) Edit existing remote n) New remote d) Delete remote r) Rename remote c) Copy remote s) Set configuration password q) Quit config e/n/d/r/c/s/q> n # 输入 n,新建 name> onedrive # 输入网盘名称,类似标签,这是用来区别不同的网盘。 Type of storage to configure. Enter a string value. Press Enter for the default (""). Choose a number from below, or type in your own value 1 / 1Fichier \ (fichier) 2 / Akamai NetStorage \ (netstorage) 3 / Alias for an existing remote \ (alias) 4 / Amazon Drive \ (amazon cloud drive) 5 / Amazon S3 Compliant Storage Providers including AWS, Alibaba, Ceph, Digital Ocean, Dreamhost, IBM COS, Lyve Cloud, Minio, RackCorp, SeaweedFS, and Tencent COS \ (s3) 6 / Backblaze B2 \ (b2) 7 / Better checksums for other remotes \ (hasher) 8 / Box \ (box) 9 / Cache a remote \ (cache) 10 / Citrix Sharefile \ (sharefile) 11 / Compress a remote \ (compress) 12 / Dropbox \ (dropbox) 13 / Encrypt/Decrypt a remote \ (crypt) 14 / Enterprise File Fabric \ (filefabric) 15 / FTP Connection \ (ftp) 16 / Google Cloud Storage (this is not Google Drive) \ (google cloud storage) 17 / Google Drive \ (drive) 18 / Google Photos \ (google photos) 19 / Hadoop distributed file system \ (hdfs) 20 / Hubic \ (hubic) 21 / In memory object storage system. \ (memory) 22 / Jottacloud \ (jottacloud) 23 / Koofr, Digi Storage and other Koofr-compatible storage providers \ (koofr) 24 / Local Disk \ (local) 25 / Mail.ru Cloud \ (mailru) 26 / Mega \ (mega) 27 / Microsoft Azure Blob Storage \ (azureblob) 28 / Microsoft OneDrive \ (onedrive) 29 / OpenDrive \ (opendrive) 30 / OpenStack Swift (Rackspace Cloud Files, Memset Memstore, OVH) \ (swift) 31 / Pcloud \ (pcloud) 32 / Put.io \ (putio) 33 / QingCloud Object Storage \ (qingstor) 34 / SSH/SFTP Connection \ (sftp) 35 / Sia Decentralized Cloud \ (sia) 36 / Storj Decentralized Cloud Storage \ (storj) 37 / Sugarsync \ (sugarsync) 38 / Transparently chunk/split large files \ (chunker) 39 / Union merges the contents of several upstream fs \ (union) 40 / Uptobox \ (uptobox) 41 / Webdav \ (webdav) 42 / Yandex Disk \ (yandex) 43 / Zoho \ (zoho) 44 / http Connection \ (http) 45 / premiumize.me \ (premiumizeme) 46 / seafile \ (seafile) Storage> 28 # 输入28表示选择Microsoft OneDrive Option client_id. OAuth Client Id. Leave blank normally. Enter a value. Press Enter to leave empty. client_id> # 输入 Client Id (客户端 ID) Microsoft App Client Secret Leave blank normally. Enter a string value. Press Enter for the default (""). client_secret> # 输入 Client Secret (客户端密码) Edit advanced config? (y/n) y) Yes n) No y/n> n # 输入 n Remote config Make sure your Redirect URL is set to "http://localhost:53682/" in your custom config. Use auto config? * Say Y if not sure * Say N if you are working on a remote or headless machine y) Yes n) No y/n> n # 输入 n For this to work, you will need rclone available on a machine that has a web browser available. Execute the following on your machine (same rclone version recommended) : rclone authorize "onedrive" "client_id" "client_secret" Then paste the result below: result> {"access_token":"XXXXXXXXX","expiry":"2024-05-15T21:18:39.5036298+08:00"} # 输入 token Choose a number from below, or type in an existing value 1 / OneDrive Personal or Business \ "onedrive" 2 / Root Sharepoint site \ "sharepoint" 3 / Type in driveID \ "driveid" 4 / Type in SiteID \ "siteid" 5 / Search a Sharepoint site \ "search" Your choice> 1 # # 这里询问你要选择的类型,因为你使用的是OneDrive,所以输入1 Found 1 drives, please select the one you want to use: 0: OneDrive (business) id=xxxxxxxxxxxxxx Chose drive to use:> 0 # 检测到网盘,此处号码是0,所以输入0 Found drive 'root' of type 'business', URL: https:// xxx.sharepoint. com/personal/xxxxxx/Documents Is that okay? y) Yes n) No y/n> y # 请你确认,如果没有问题,请输入 y -------------------- [od-e5-api] type = onedrive client_id = xxxxxxxxxx client_secret = xxxxxxxxxxxxxxxx token = {"access_token":"xxxxxxxxxxxxxxxxxx","expiry":"2024-05-15T21:18:39.5036298+08:00"} drive_id = xxxxxxxxxxxxxxxxxxxxxxxxx drive_type = business -------------------- y) Yes this is OK e) Edit this remote d) Delete this remote y/e/d> y # 最后会显示网盘的配置信息,请确认是否准确无误? 如果没有问题,请输入 y Current remotes: Name Type ==== ==== onedrive onedrive e) Edit existing remote n) New remote d) Delete remote r) Rename remote c) Copy remote s) Set configuration password q) Quit config e/n/d/r/c/s/q> q # 输入 q 退出
- Gu ruige seo, tha Rclone air ceangal soirbheachail a dhèanamh ri diosc lìonra OneDrive a’ cleachdadh an API fèin-thogte.
Nuair a bhios tu deiseil, faodaidh tu na leanas a chleachdadhrclone
Òrdugh airson fhaicinn:
Dèan liosta de chlàran aig an ìre as àirde de onedrive▼
rclone lsd onedrive:
Dèan liosta de na faidhlichean uile ann an onedrive▼
rclone ls onedrive:
Dèan lethbhreac den eòlaire ionadail gu eòlaire ainmichtebackup
eòlaire onedrive ▼
rclone copy /home/source onedrive:backup
Dèan lethbhreac dheth Delete Command
Dèan lethbhreac den fhaidhle rèiteachaidh Rclone gu eòlaire freumh an diosc lìonra onedrive ▼
rclone copy /root/.config/rclone/rclone.conf onedrive:/
dèan lethbhreac ionadail /home/backup
Rach don eòlaire cùl-taic far a bheil an diosc lìonra ainmichte onedrive air a rèiteachadh, agus a chaochladh ▼
rclone copy --progress /home/backup onedrive:backup
- le bhith a’ cur am paramadair seo ris
--ignore-existing
Faodar dearmad a dhèanamh air faidhlichean a fhuair taic air diosc an lìonraidh, a tha co-ionann ri cùl-taic mean air mhean ▼
rclone copy --ignore-existing /home/backup onedrive:backup
Dèan lethbhreac den fhaidhle cùl-taic làimhe CWP ionadail gu eòlaire cùl-taic an diosc lìonra ainmichte onedrive, agus a chaochladh ▼
rclone copy --progress /newbackup/full/manual/accounts/eloha.tar.gz onedrive:cwp-newbackup/full/manual/accounts/
Bhon diosc lìonra onedrive, dèan lethbhreac den fhaidhle cùl-taic fèin-ghluasadach CWP chun chlàr ionadail /newbackup
Catalog ▼
rclone copy --progress onedrive:cwp-newbackup/full/daily/Friday/accounts/eloha.tar.gz /newbackup/ rclone copy --progress onedrive:cwp-backup2/ /home/backup2/
Bhon diosc lìonra onedrive, dèan lethbhreac den fhaidhle cùl-taic làimhe CWP chun fhear ionadail /newbackup/newbackup/full/manual/accounts/
catalog ▼
rclone copy --progress onedrive:cwp-newbackup/full/manual/accounts/eloha.tar.gz /newbackup/newbackup/full/manual/accounts/
Dèan lethbhreac dheth o dhiosca lìonra onedriveVestaCPFaidhlichean cùl-taic gu ionadail /home/backup
Catalog ▼
rclone copy --progress onedrive:backup/admin.2018-04-12_13-10-02.tar /home/backup
Gluasad (Gearr) Òrdugh ▼
rclone move /home/backup onedrive:backup
Sguab às an eòlaire cùl-taic den diosc lìonra leis an ainm rèiteachaidh onedrive▼
rclone delete onedrive:backup
Cruthaich eòlaire cùl-taic a rèiticheas diosc lìonra leis an ainm onedrive ▼
rclone mkdir onedrive:backup
Dèan lethbhreac ▼
rclone copy
gluais ▼
rclone move
sguab às ▼
rclone delete
Sioncronaich ▼
rclone sync
Airson barrachd chlasaichean teagaisg cleachdadh àithne Rclone, thoir sùil air cruinneachadh òrdughan Rclone gu h-ìosal▼
Ciamar a stàladh OneDrive?
Ma dh’ fheumas tu a dhol gu eòlaire ionadail, faodaidh tu sùil a thoirt air an oideachadh sreap Rclone a bh’ againn roimhe▼
Cuingeachaidhean air OneDrive Private API
Ged is urrainn do APIan prìobhaideach fèin-thogte an t-eòlas luchdachadh suas a leasachadh, dh’ fhaodadh an luchdachadh suas a bhith cuibhrichte ma thèid a chleachdadh ro thric.
Dè an ìre as àirde a th’ ann airson API Microsoft OneDrive?
Chan eil Microsoft air innse gu soilleir dè an ìre as àirde a th’ ann an API OneDrive. Seo an sgrìobhainn thùsail:
Stèidhichte air cleachdadh, bidh sinn a’ gleusadh na stairsnich gus an urrainn do luchd-cleachdaidh an ìre as motha de ghoireasan a chleachdadh gun a bhith a’ toirt buaidh air earbsachd agus coileanadh.
- Mar as urrainn dhut tomhas bho bhith a’ coimhead air an tuairisgeul air seòrsachan eile de chrìochan API, tha dà chrìoch ann, iomlan agus tricead.
- Is e an àireamh iomlan an àireamh de ghlaodhan a ghabhas dèanamh ann an latha, agus is e tricead an àireamh de ghlaodhan a ghabhas dèanamh gach mionaid.
- Agus aon uair ‘s gu bheil an stairsneach smeòrach air a ruighinn, thathas a’ luchdachadh suas faidhle.
- Leis nach fhaighear an dearbh luach bho na sgrìobhainnean oifigeil, an urrainnear an dearbh luach seo fhaighinn tro fhìor dheuchainn?
- tha am freagairt àicheil.Cha deach riaghailtean sam bith a lorg anns an fhìor dheuchainn, agus mar sin tha a’ chrìoch seo air atharrachadh gu fiùghantach agus a rèir na sgrìobhainnean oifigeil.
Ciamar as urrainn dhomh a bhith air mo chuingealachadh leis an OneDrive API?
Na luchdaich suas cus fhaidhlichean ann an ùine ghoirid, chan eil meud an fhaidhle gu diofar, is e an iuchair an àireamh de fhaidhlichean.
Mu Office 365 E5 ùrachadh gu fèin-ghluasadach:
- A rèir eòlas luchd-cleachdaidh a tha a’ cleachdadh dreach deuchainn an leasaiche airson grunn bhliadhnaichean, fhad ‘s a chleachdas tu an API prìobhaideach fèin-thogte, faodaidh tu an fho-sgrìobhadh ùrachadh.
- A thaobh tricead, chan eil inbhe ann, agus mar as motha is ann as fheàrr.
- Is dòcha nach b ’fhiach a bhith a’ bruiseadh an API a dh’aona ghnothach, gu sònraichte a ’cleachdadh GitHub Actions, leis gur e Microsoft Azure an t-seirbheisiche, tha uimhir de dhaoine a’ cleachdadh dhòighean coltach ris gus an API a bhrùthadh gun bhrìgh, tha Microsoft Azure airson a chomharrachadh gu bheil e furasta.
An dòchas blog Chen Weiliang ( https://www.chenweiliang.com/ ) co-roinnte “Tha Rclone slaodach gus ceangal ri Onedrive?Dump crìoch astair luchdachadh suas? Dèan rèiteachadh API luathachadh" gus do chuideachadh.
Fàilte gus ceangal an artaigil seo a cho-roinn:https://www.chenweiliang.com/cwl-27906.html
Fàilte don t-sianal Telegram de bhlog Chen Weiliang gus na h-ùrachaidhean as ùire fhaighinn!
📚 Tha luach mòr anns an stiùireadh seo, 🌟 Is e cothrom ainneamh a tha seo, na caill e! ⏰⌛💨
Roinn agus toil ma thogras tu!
Is e do roinneadh agus do rudan mar ar brosnachadh leantainneach!