This packages helps to upload and delete files to s3.
Project description
Python Script to upload files to AWS
This script is a wrapper over boto3 which makes developer easy to upload files to AWS
Getting Started
Steps to get started:-
- pip install s3manager
Steps to Use:-
- from s3manager import S3manager
- s3_object_manager = S3manager(bucket_name="bucketname", access_key=<access_key>, access_secret=<access_secret>)
- s3_object_manager.upload_file(file_name=<file_name>, filepath=, acl='public-read')
- In response result will have url to the file uploaded and the key name of file in bucket
- to delete the object s3_object_manager.delete_file(key)
To get pre signed url
1.from s3manager import S3manager 2. s3_manager=S3manager(bucket_name=,access_key= ,access_secret=) 3. s3_manager.generate_pre_signed_url(obj_key=s3_object_key, region_name=,expires_in=86400)
Prerequisites
boto3 should be installed
Built With
- [python3]
- [boto3]
Authors
- Anshul Gupta - Initial work - [AwsS3Manager]
License
This project is licensed under the MIT License - see the LICENSE.md file for details
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
s3manager-1.2.1.tar.gz
(2.5 kB
view hashes)
Built Distribution
s3manager-1.2.1-py3-none-any.whl
(15.1 kB
view hashes)
Close
Hashes for s3manager-1.2.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a852984e86840e06b2717c9290464a68244ac9808152eab2e05f2f5dd7c27531 |
|
MD5 | af98f2ee677d780168cc435d90c55887 |
|
BLAKE2b-256 | cf9488c63fd97dd7b893373d66f931f8f3a8bb525697be0958e51581c922c35b |