如何从 CLI Cyber​​Duck 访问 Google 驱动器?

How to access Google Drive from CLI CyberDuck?

经过长时间的搜索,我发现对于需要在 Linux 和 Google 之间传输文件的用户来说,似乎是最佳实践解决方案驱动器:

https://cyberduck.io/?l=en

CLI 版本是最新的,其文档不清楚。

Google 存储的 URL 格式为:

gs://[容器]/[键]

我的 Google 云端硬盘帐户是基本的免费赠品。我环顾四周,但不知道如何确定我的 [container] 和 [key]。

TIA。

加法:

我发现“[container]”与 "bucket" 相同。然而,“[key]”仍然是个谜。

根据找到的信息 here

Google Storage and Google Drive — which storage API should my application use? Google provides two different storage services: Google Cloud Storage, and Google Drive. Both services allow programmatic access to their functionality, but the goals of the APIs are quite different. The Google Drive SDK works together with the Google Drive UI and the Chrome Web Store to create an ecosystem of apps that can be installed into Google Drive. These apps enhance the user experience by allowing users to interact with their data in novel ways. For instance, a user could install a Drive app to edit images or fax PDF files, and could create and open files with those apps directly in Google Drive.

Google Cloud Storage is intended to be accessed primarily through its API and provides all the functionality necessary for developers to use it as a backing store for their own applications. For example, a developer could store and host media and other static assets for a web game in Google Cloud Storage. Google Cloud Storage can also be used for online archives, backup replacement, and so on.

This illustrates the primary difference between the two APIs: Cloud Storage enables developers to store their application data in the Google cloud (and they’re responsible for the storage their app consumes), whereas in Drive, users allow apps to interact with the user’s private storage and content.

For an overview of Google storage options, including a video explaining the differences between the options, see Storing Your Data.

您不太可能获得存储在 Google Drive 中的数据的存储桶和密钥 ID。如果 Google 为 Drive 与 Cloud Storage 使用其他一些基础设施(我认为 Drive 是建立在 Cloud Storage 上的),我会感到惊讶,但由于 Drive 本质上是一个建立在 Cloud Storage 上的应用程序,因此使用的存储桶和密钥不会暴露提高使用率。

此外,other folks 似乎和我说的一样... Gsutil,因此 gs:// 获取文件的方式不适用于 Google 驱动器。

这个消息一点都不好。据此:

https://trac.cyberduck.io/wiki/help/en/howto/googledocs

Cyber​​Duck 对 Google Drive 的支持已停止。

R.I.P.

对于那些感兴趣的人,经过艰苦的研究,我发现唯一能够连接 CLI Linux 和 Google Drive 的应用程序是不同步。

https://www.insynchq.com/downloads

https://insync.io

您可以免费试用一段时间,测试版也是免费的。

但是它有问题。 32 位版本仅适用于 32 位机器。有一个 64 位版本仅适用于基于 AMD 的 Linux 机器。

他们的文档很糟糕,但这就是您所需要的:

% mkdir ~/MyGoogleDrive

% ./insync-portable start

[这将在 /tmp 中创建一个文件。按照说明通过网络浏览器获取代码]

% ./insync-portable add_account  [code]   ~/MyGoogleDrive

您必须与程序位于同一目录中,这一要求由上面的句点和斜杠表示。

官方 Google 实用程序 gsutil 仅适用于其付费服务 Google Cloud Storage .