HaschekSolutions / pictshare

:camera: PictShare is an open source image, mp4, pastebin hosting service with a simple resizing and upload API that you can host yourself. :rice_scene:
https://www.pictshare.net
Apache License 2.0
819 stars 123 forks source link

Introduce Storage Providers #61

Closed birkett closed 5 years ago

birkett commented 6 years ago

This started out as a refactor of the Backblaze support - but turned into a storage structure concept.

StorageProviders are ways to store and retrieve files. Currently, we have:

The application is not fully utilising LocalStorageProvider yet. There are still some calls to GD functions, which are directly saving images locally.

Eventually, we should be able to have multiple StorageProviders enabled, configured via config / env vars.

This also paves the way to Amazon S3 support - linking to #49

Breaking changes: PHP 7.0 required (type hints, strict types) Functionality changes: Rotating images is now treated as a filter (backwards compatible).

This PR is branched off #60. I recommend a full test before merging.

Linking to #57