Saving data on OneDrive or Google Drive (Heroku)

泄露秘密 提交于 2021-02-11 12:26:24

问题


Hello I am new to using django and heroku and through out me designing my first project I Found out that I need a AWS 3 account/S3 storage to store images/files but I was wondering if I could use either a OneDrive or a Google Drive to save the files/images that the user uploads and if so, is it Like when using a AWS 3 storage.


回答1:


Heroku has an “ephemeral” hard drive, this means that you can write files to disk, but those files will not persist after the application is restarted. You would get them lost in case you restart your dyno or deploy a new release (Active Storage on Heroku.

But you have a few options to get your data stored although that is the case.

  1. Use one of Herokus services to do so and pay for it (Databases & Data Management
  2. Use one of the third party providers which offer their services at Herokus marketplace and pay for it (Heroku Add-ons
  3. Use one of your personal preferred other providers which offers such kind of data storage service (e.g. one of those: HDrive.

Which options would fit your plan depends a bit on your application and the kind of data you want to store. You are using a sqlite-db and need an additional file storage and all together needs to be migrated to Heroku: Migrating your Django Project to Heroku



来源:https://stackoverflow.com/questions/64824365/saving-data-on-onedrive-or-google-drive-heroku

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!