A customer loader for getting the video first frame from s3 compatible storage
Project description
Thumbor AWS
Installation
pip install tc_aws_video
Authentication
Authentication is handled by botocore, see Boto3 documentation.
Origin story
If you store the images or videos in s3 compatible storage , such as aws , minio etc.
And now, you want to access the images or the first frame of the videos on it.
This is a custom loader will help you to do this!
Features
version | loader | python version | change log desc |
---|---|---|---|
v1.0.2 | tc_aws_video.s3_video_loader |
python2 | Add feature to cut the first frame of video |
v1.1.2 | tc_aws_video.loaders.s3_video_loader |
python2 | Optimize code to speed up loading |
Additional Configuration values used:
# Reuse tc_aws configs
# If you have credentials in ~/.aws/credentials ,
# then you can ignore TC_AWS_LOADER_ACCESS_KEY and TC_AWS_LOADER_SECRET_KEY
TC_AWS_REGION='your-s3-region'
TC_AWS_ENDPOINT='your-s3-endpoint'
TC_AWS_LOADER_ACCESS_KEY='your-s3-accesskey'
TC_AWS_LOADER_SECRET_KEY='your-s3-secret'
# Customize the temp storage for first frame of video
# The loader will delete the temp file while it read it into memory
TC_AWS_LOADER_VIDEO_FRAME_CACHE='/path/to/your/cache'
# Enable this loader
# When using v1.0.2
# LOADER = 'tc_aws_video.s3_video_loader'
# When using v1.1.2+
LOADER = 'tc_aws_video.loaders.s3_video_loader'
# Pay attention to this config
# If you have cdn to access this , then you can set to no_storage
# STORAGE = "thumbor.storages.no_storage"
# else if you just want to cache the file into local storage , you can use file_storage
# but you should remember , if you use the file_storage , the files will persistent in the file system until you remove them
STORAGE = "thumbor.storages.file_storage"
STORAGE_EXPIRATION_SECONDS = 900
FILE_STORAGE_ROOT_PATH = '/path/to/you/cache'
RESULT_STORAGE = 'thumbor.result_storages.file_storage'
RESULT_STORAGE_EXPIRATION_SECONDS=900
RESULT_STORAGE_FILE_STORAGE_ROOT_PATH = '/path/to/you/cache'
RESULT_STORAGE_STORES_UNSAFE = True
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
tc_aws_video-1.1.2.tar.gz
(8.0 kB
view details)
Built Distribution
File details
Details for the file tc_aws_video-1.1.2.tar.gz
.
File metadata
- Download URL: tc_aws_video-1.1.2.tar.gz
- Upload date:
- Size: 8.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.15.0 pkginfo/1.8.3 requests/2.27.1 setuptools/44.1.1 requests-toolbelt/1.0.0 tqdm/4.64.1 CPython/2.7.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3e87e7b65579326fd95f0e7ffa93ea4c93be9007f14717513346e81a317792ee |
|
MD5 | edf64fc5647cfd82e30375cd2a2a20dc |
|
BLAKE2b-256 | 192098e6cadaca767e093fdca9dc7190c518c5a04f1cfa5cb5130ff9311abd35 |
File details
Details for the file tc_aws_video-1.1.2-py2-none-any.whl
.
File metadata
- Download URL: tc_aws_video-1.1.2-py2-none-any.whl
- Upload date:
- Size: 13.8 kB
- Tags: Python 2
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.15.0 pkginfo/1.8.3 requests/2.27.1 setuptools/44.1.1 requests-toolbelt/1.0.0 tqdm/4.64.1 CPython/2.7.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cefc3d4484d2d7843ec68e92d64688c58377acbc6cdaf52833eef39b61b85166 |
|
MD5 | 51337fb476cdcc36539576fae7e4ff73 |
|
BLAKE2b-256 | 2343ce610cfc606c3402de7857ca25f3b7ff3f40f9db8b6a6aeba0662871124e |