将zip文件直接从网站上传到AWS S3存储桶?

发布于 2025-01-21 10:32:11 字数 972 浏览 3 评论 0原文

是否可以将数据文件从网站直接上传到AWS S3存储桶,而不必先将文件下载到我的PC上?这些是大文件(60 GB),将我的PC绑起来一周下载,准备,然后将桌子上传到我的S3存储桶中。

我在我的S3管理控制台中看到了“添加文件”和“添加文件夹”的选项,但我看不到可以输入数据文件的原始URL位置的地方。

数据文件位于此处(滚动到页面底部); URLs for the data are:

https://acic2022.mathematica.org/data/track1a_20220404.zip< /a>

https://acic2022.mathematica.org/data.org/data/data/data/track1b_2022022022022022022022022022022022022022022044.zip

https://acic20222.mathematica.orgg/data/data/data/data/data/track1c_2022022022044.zip </

afect

Is it possible to directly upload data files from a website to an AWS S3 bucket without having to first download the files to my PC? These are large files (60 GB) and will tie up my PC for a week downloading, prepping, and then uploading the tables to my S3 bucket.

I see in my S3 Management Console there are options to "Add files" and "Add folder" but I don't see a place where I can enter the original URL location of the data files.

The data files are located here (scroll to bottom of page); URLs for the data are:

https://acic2022.mathematica.org/data/track1a_20220404.zip

https://acic2022.mathematica.org/data/track1b_20220404.zip

https://acic2022.mathematica.org/data/track1c_20220404.zip

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

你是年少的欢喜 2025-01-28 10:32:11

因此,下面的脚本对于小文件效果很好,换句话说,您必须等到下载结束,然后才能将上传到Bucket S3初始化,这可能需要很长时间。在此期间,您只会看到创建的存储桶。

将为默认区域:us-east-1创建存储桶。一旦您需要通过自动化流程处理AWS CLI,则具有管理权限的程序化用户是强制性的。

您只需要更改必须是源路径的最后一个节点的变量文件

FILE="track1a_20220404.zip"
BCKT="math-files-s3"
SRC="https://acic2022.mathematica.org/data/$FILE"
aws s3api create-bucket --bucket $BCKT | \
wget -O- $SRC | aws s3 cp - s3://$BCKT/$FILE

只是编辑以提供屏幕截图作为工作证明...

​/I.SSTATIC.NET/8LX77.PNG“ ALT =” Enter Image Description在此处”>

So, the below script worked well for small files, in other words, you have to wait until the download ends the process before it initializes the upload to bucket s3, which might take a long while. During that time you'll only see the bucket created.

The bucket will be created for the default zone: us-east-1. A programmatic user is mandatory with admin permissions, once you will need to deal with AWS CLI through an automated process.

You'll only need to change the variable FILE that has to be the last node of your source path.

FILE="track1a_20220404.zip"
BCKT="math-files-s3"
SRC="https://acic2022.mathematica.org/data/$FILE"
aws s3api create-bucket --bucket $BCKT | \
wget -O- $SRC | aws s3 cp - s3://$BCKT/$FILE

Just editing to provide screenshots as proof of work...
enter image description here

enter image description here

enter image description here

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文