作者:挠挠扣扣笑嘻嘻 | 来源:互联网 | 2023-08-01 12:41
ImusingaDjangoserverhostedonEC2Singapore.ImalsousinganS3buckettosavefilesuploade
I'm using a Django server hosted on EC2 Singapore. I'm also using an S3 bucket to save files uploaded through the Django Admin panel. To upload files, I'm using django-s3direct
.
我正在使用在新加坡EC2上托管的Django服务器。我还使用S3存储桶来保存通过Django Admin面板上传的文件。要上传文件,我正在使用django-s3direct。
When I upload files using my local machine on Eastern American time, it prevents me from uploading the files citing:
当我在美国东部时间使用本地计算机上传文件时,它阻止我上传文件,引用:
Invalid according to Policy: Policy expired.
I've tried the solutions from:
Fine Uploader getting "Policy expired" message sending to S3 for some and here: https://github.com/FineUploader/fine-uploader/issues/1387
我已经尝试过以下解决方案:Fine Uploader将“Policy expired”消息发送到S3以获取一些和此处:https://github.com/FineUploader/fine-uploader/issues/1387
When I check the uploaded time and the UTC time, there's no difference. How do I fix this error?
当我检查上传时间和UTC时间时,没有区别。我该如何解决这个错误?
EDIT: To be noted, the upload works perfectly on localhost but doesn't work on the server hosted on AWS EC2.
编辑:需要注意的是,上传在localhost上完美运行,但在AWS EC2上托管的服务器上不起作用。
1 个解决方案