Fast ZIP/UNZIP utility for S3 with same-account and cross-account support.
Project description
🚀 s3-zipper
High-performance, memory-safe ZIP/UNZIP utility for Amazon S3
Supports same-account and cross-account (STS assume-role) operations.
Streams zip files directly between S3 buckets without storing on disk.
✨ Features
- 🔥 True streaming ZIP creation — no local temp files needed
- 🌉 Cross-account S3 copy using AWS STS
AssumeRole - 📦 Streaming ZIP extraction — handles very large ZIPs without RAM blow-ups
- 🧪 Fully tested (pytest + moto)
- 🖥️ CLI included: use
s3-zipperfrom shell - 🧰 Pure Python package (
boto3,zipstream)
📦 Installation
pip install s3-zipper
ZIP FLOW (S3 → ZIP → S3)
This flow zips all objects under a given prefix in one bucket and streams the ZIP directly into another bucket.
CLI Usage
s3-zipper \
--flow zip \
--source-s3-bucket my-source-bucket \
--source-s3-key data/prefix/ \
--target-s3-bucket my-target-bucket \
--target-s3-key output/my-archive.zip \
--region us-east-1
With cross account role
s3-zipper \
--flow zip \
--source-s3-bucket src-bucket \
--source-s3-key logs/ \
--target-s3-bucket dest-bucket \
--target-s3-key backups/logs.zip \
--source-role-arn arn:aws:iam::111111111111:role/SourceReadRole \
--target-role-arn arn:aws:iam::222222222222:role/WriteZipRole \
--region us-east-1
UNZIP FLOW (ZIP in S3 → Extracted files → S3)
Streams each file from a ZIP stored in S3 and uploads each file individually to another S3 location — no disk needed.
s3-zipper \
--flow unzip \
--source-s3-bucket my-bucket \
--source-s3-key archives/my.zip \
--target-s3-bucket my-output \
--target-s3-key extracted/
Python API Usage
from s3_zipper.s3_client import get_s3_client
from s3_zipper.zip_flow import zip_s3_s3
from s3_zipper.unzip_flow import unzip_s3_s3
# Same-account client
client = get_s3_client(region="us-east-1")
# ZIP: s3://src-bucket/data/* → s3://dest-bucket/archive.zip
zip_s3_s3(
args=SimpleNamespace(
source_s3_bucket="src-bucket",
source_s3_key="data/",
target_s3_bucket="dest-bucket",
target_s3_key="archive.zip",
same_account=True,
source_role_arn=None,
target_role_arn=None
),
source_s3=client,
target_s3=client
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file s3_zipper-0.1.0.tar.gz.
File metadata
- Download URL: s3_zipper-0.1.0.tar.gz
- Upload date:
- Size: 5.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d850b85f215ef3e11303ed537de7057cdf4fb1603897782ce63f3be191ef6f16
|
|
| MD5 |
0d465cb2b5ab109261a6a9f5d58632ce
|
|
| BLAKE2b-256 |
b10d6e3ae8a968a5b36a5d9099504dd64ae2a90219ee3234a6ef9e376a3ac90d
|
File details
Details for the file s3_zipper-0.1.0-py3-none-any.whl.
File metadata
- Download URL: s3_zipper-0.1.0-py3-none-any.whl
- Upload date:
- Size: 8.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ec4de9092f6abb59006aeb79a584d9ea7118d50f2f142dd86136ff80813b4638
|
|
| MD5 |
ba6604cc1b7350fe540d57e01916b995
|
|
| BLAKE2b-256 |
2dc4181aa35ee17c679bdd033bfe85b259c72aca87d172afbf593ee2c9fdb4d5
|