Data storage made simple.
- File system
- AWS S3
- Google Cloud Storage
- Python >= 3.6
Install the package:
pip install simple-storage
Now, depending on the storage you want to use, follow the instructions below.
Environment variable | Value |
---|---|
STORAGES_BACKEND |
storages.backends.file_system.FileSystemStorage |
STORAGES_PATH |
Point to the existing path in your file system, e.g. /app/media . |
Environment variable | Value |
---|---|
STORAGES_BACKEND |
storages.backends.amazon_s3.AmazonS3Storage |
STORAGES_AWS_ACCESS_KEY_ID |
Your AWS access key ID. |
STORAGES_AWS_SECRET_ACCESS_KEY |
Your AWS secret access key. |
STORAGES_AWS_BUCKET_NAME |
The bucket name that you want to use. |
In case you encounter any problems with finding your AWS credentials please read this page as a reference.
Environment variable | Value |
---|---|
STORAGES_BACKEND |
storages.backends.google_cloud.GoogleCloudStorage |
STORAGES_GOOGLE_CLOUD_CREDENTIALS |
Your Google Cloud Storage credentials in JSON encoded using Base64. |
STORAGES_GOOGLE_CLOUD_BUCKET_NAME |
The bucket name that you want to use. |
The documentation is hosted on the project's GitHub Wiki.