This PR is pretty much the same as the one submitted to dev-workerbuild yesterday, but now to dev instead. It introduces AWS S3 buckets as storage, and fixes quirks related to the original implementation of local storage. In addition, support for using Heroku-addon "Bucketeer" has been added as a possible way to use S3 storage.
Changelog
Deploy to Heroku workflow
Set Env to use Bucketeer for storage
.env.example
Added STORAGE_TYPE, used for switching between storage types
Added AWS S3 bucket config variables
Added Bucketeer AWS S3 bucket config variables
routers/georefProject
Created section to choose storage type based on env (local, s3, bucketeer)
Updated various routes to use bytes rather than file paths
getTile now returns a FastAPI response rather than a direct tile
utils/core/georefHelper
generateTile now takes bytes rather than a file path
generateTile now returns a tuple with bytes and path to temp file rather than a FastAPI response
utils/projectHandler
Various changes to use bytes rather than file paths.
utils/storage/files/s3FileStorage
Adds AWS S3 bucket storage as a file storage implementation, based on the abstract fileStorage-class
This PR is pretty much the same as the one submitted to dev-workerbuild yesterday, but now to dev instead. It introduces AWS S3 buckets as storage, and fixes quirks related to the original implementation of local storage. In addition, support for using Heroku-addon "Bucketeer" has been added as a possible way to use S3 storage.
Changelog
Deploy to Heroku workflow
.env.example
routers/georefProject
utils/core/georefHelper
utils/projectHandler
utils/storage/files/s3FileStorage
pyproject.toml and requirements.txt