# ๐ณ S3Docker
## ๐ฏ Why S3Docker?
Managing Docker images across multiple environments and teams can be challenging:
- Private registries can be expensive and complex to maintain
- Manual image transfer is time-consuming and error-prone
- Version management and rollbacks can be difficult
S3Docker solves these problems by:
- Using AWS S3 as a cost-effective storage solution
- Providing simple commands for image management
- Automatically handling versioning and archiving
- Supporting multiple configuration profiles for different environments
## โจ Features
- ๐ฆ Simple push/pull commands for Docker images
- ๐ Automatic version archiving
- ๐ Multiple named configuration profiles
- ๐ Image listing with size and modification info
- ๐งน Automatic cleanup of temporary files
- ๐ Secure AWS credentials management
## ๐ Installation
```bash
pip install s3docker
```
## ๐ Prerequisites
- Python 3.6 or higher
- Docker installed and running
- AWS account with S3 access
- AWS credentials with the following permissions:
- `s3:PutObject`
- `s3:GetObject`
- `s3:ListBucket`
## ๐ ๏ธ Configuration
### Initial Setup
```bash
s3docker config
```
Follow the interactive wizard to configure:
1. Profile name (e.g., 'prod', 'staging', 'default')
2. AWS Access Key ID
3. AWS Secret Access Key
4. AWS Region (default: us-east-1)
5. S3 Bucket name
6. S3 Path prefix (default: docker-images)
### Managing Multiple Profiles
List all configured profiles:
```bash
s3docker configs
```
## ๐ Usage Guide
### Pushing Images to S3
```bash
# Using default profile
s3docker push myapp:latest
# Using specific profile
s3docker push myapp:latest --to prod
# Replace existing image
s3docker push myapp:latest --replace
# Specify temporary directory
s3docker push myapp:latest --temp /path/to/temp
s3docker push myapp:latest --temp . # Use current directory
```
### Pulling Images from S3
```bash
# Using default profile
s3docker pull myapp:latest
# Using specific profile
s3docker pull myapp:latest --from prod
# Specify temporary directory
s3docker pull myapp:latest --temp /path/to/temp
s3docker pull myapp:latest --temp . # Use current directory
```
### Listing Available Images
```bash
# List images in default profile
s3docker list
# List images in specific profile
s3docker list --from prod
```
## ๐ง How It Works
1. **Push Operation**:
- Saves Docker image to temporary tar file
- If image exists in S3:
- Moves existing image to archive folder (if --replace not used)
- Archives include timestamps for version tracking
- Uploads new image to S3
- Cleans up temporary files
2. **Pull Operation**:
- Downloads tar file from S3
- Loads image into Docker
- Automatically removes temporary files
3. **Configuration Storage**:
- Configs stored in `~/.s3docker/configs.json`
- Separate profiles for different environments
- Secure credential storage
## ๐ Best Practices
1. **Profile Management**:
- Use different profiles for development/staging/production
- Keep production credentials separate
- Regular credential rotation
2. **Image Management**:
- Use specific tags instead of 'latest'
- Utilize --replace flag carefully
- Regular cleanup of archived versions
## ๐ค Contributing
1. Fork the repository
2. Create your feature branch
3. Commit your changes
4. Push to the branch
5. Create a Pull Request
## ๐ License
MIT License - feel free to use and modify as needed!
## ๐ Support
- Create an issue for bug reports
- Feature requests are welcome
- PRs accepted
## ๐ฎ Future Plans
- [ ] Support for image tags listing
- [ ] Bulk upload/download
- [ ] Compression options
- [ ] Image metadata support
- [ ] Integration with CI/CD pipelines
---
Made with โค๏ธ for the Docker community
Raw data
{
"_id": null,
"home_page": "https://github.com/Kawai-Senpai/s3Docker",
"name": "s3docker",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.6",
"maintainer_email": null,
"keywords": null,
"author": "Ranit Bhowmick",
"author_email": "bhowmickranitking@duck.com",
"download_url": "https://files.pythonhosted.org/packages/9e/47/2d685330cb17277126960ce98ec1637ac13be642513ef93b75daf2d20876/s3docker-1.1.2.tar.gz",
"platform": null,
"description": "# \ud83d\udc33 S3Docker\r\n\r\n## \ud83c\udfaf Why S3Docker?\r\n\r\nManaging Docker images across multiple environments and teams can be challenging:\r\n- Private registries can be expensive and complex to maintain\r\n- Manual image transfer is time-consuming and error-prone\r\n- Version management and rollbacks can be difficult\r\n\r\nS3Docker solves these problems by:\r\n- Using AWS S3 as a cost-effective storage solution\r\n- Providing simple commands for image management\r\n- Automatically handling versioning and archiving\r\n- Supporting multiple configuration profiles for different environments\r\n\r\n## \u2728 Features\r\n\r\n- \ud83d\udce6 Simple push/pull commands for Docker images\r\n- \ud83d\udd04 Automatic version archiving\r\n- \ud83d\udcdd Multiple named configuration profiles\r\n- \ud83d\udcca Image listing with size and modification info\r\n- \ud83e\uddf9 Automatic cleanup of temporary files\r\n- \ud83d\udd12 Secure AWS credentials management\r\n\r\n## \ud83d\ude80 Installation\r\n\r\n```bash\r\npip install s3docker\r\n```\r\n\r\n## \ud83d\udccb Prerequisites\r\n\r\n- Python 3.6 or higher\r\n- Docker installed and running\r\n- AWS account with S3 access\r\n- AWS credentials with the following permissions:\r\n - `s3:PutObject`\r\n - `s3:GetObject`\r\n - `s3:ListBucket`\r\n\r\n## \ud83d\udee0\ufe0f Configuration\r\n\r\n### Initial Setup\r\n\r\n```bash\r\ns3docker config\r\n```\r\n\r\nFollow the interactive wizard to configure:\r\n1. Profile name (e.g., 'prod', 'staging', 'default')\r\n2. AWS Access Key ID\r\n3. AWS Secret Access Key\r\n4. AWS Region (default: us-east-1)\r\n5. S3 Bucket name\r\n6. S3 Path prefix (default: docker-images)\r\n\r\n### Managing Multiple Profiles\r\n\r\nList all configured profiles:\r\n```bash\r\ns3docker configs\r\n```\r\n\r\n## \ud83d\udcda Usage Guide\r\n\r\n### Pushing Images to S3\r\n\r\n```bash\r\n# Using default profile\r\ns3docker push myapp:latest\r\n\r\n# Using specific profile\r\ns3docker push myapp:latest --to prod\r\n\r\n# Replace existing image\r\ns3docker push myapp:latest --replace\r\n\r\n# Specify temporary directory\r\ns3docker push myapp:latest --temp /path/to/temp\r\ns3docker push myapp:latest --temp . # Use current directory\r\n```\r\n\r\n### Pulling Images from S3\r\n\r\n```bash\r\n# Using default profile\r\ns3docker pull myapp:latest\r\n\r\n# Using specific profile\r\ns3docker pull myapp:latest --from prod\r\n\r\n# Specify temporary directory\r\ns3docker pull myapp:latest --temp /path/to/temp\r\ns3docker pull myapp:latest --temp . # Use current directory\r\n```\r\n\r\n### Listing Available Images\r\n\r\n```bash\r\n# List images in default profile\r\ns3docker list\r\n\r\n# List images in specific profile\r\ns3docker list --from prod\r\n```\r\n\r\n## \ud83d\udd27 How It Works\r\n\r\n1. **Push Operation**:\r\n - Saves Docker image to temporary tar file\r\n - If image exists in S3:\r\n - Moves existing image to archive folder (if --replace not used)\r\n - Archives include timestamps for version tracking\r\n - Uploads new image to S3\r\n - Cleans up temporary files\r\n\r\n2. **Pull Operation**:\r\n - Downloads tar file from S3\r\n - Loads image into Docker\r\n - Automatically removes temporary files\r\n\r\n3. **Configuration Storage**:\r\n - Configs stored in `~/.s3docker/configs.json`\r\n - Separate profiles for different environments\r\n - Secure credential storage\r\n\r\n## \ud83c\udf1f Best Practices\r\n\r\n1. **Profile Management**:\r\n - Use different profiles for development/staging/production\r\n - Keep production credentials separate\r\n - Regular credential rotation\r\n\r\n2. **Image Management**:\r\n - Use specific tags instead of 'latest'\r\n - Utilize --replace flag carefully\r\n - Regular cleanup of archived versions\r\n\r\n## \ud83e\udd1d Contributing\r\n\r\n1. Fork the repository\r\n2. Create your feature branch\r\n3. Commit your changes\r\n4. Push to the branch\r\n5. Create a Pull Request\r\n\r\n## \ud83d\udcdd License\r\n\r\nMIT License - feel free to use and modify as needed!\r\n\r\n## \ud83c\udd98 Support\r\n\r\n- Create an issue for bug reports\r\n- Feature requests are welcome\r\n- PRs accepted\r\n\r\n## \ud83d\udd2e Future Plans\r\n\r\n- [ ] Support for image tags listing\r\n- [ ] Bulk upload/download\r\n- [ ] Compression options\r\n- [ ] Image metadata support\r\n- [ ] Integration with CI/CD pipelines\r\n\r\n---\r\n\r\nMade with \u2764\ufe0f for the Docker community\r\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "A tool to manage Docker images using S3 storage",
"version": "1.1.2",
"project_urls": {
"Homepage": "https://github.com/Kawai-Senpai/s3Docker"
},
"split_keywords": [],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "d4e663f961f522a76a86bf484ecac1bfb84f20fb55be4bcdae5614b09d8d93e1",
"md5": "89cf00ae9a9e388a2fed0a50d9889ae9",
"sha256": "b8f63166b9b48239515367727cb4e9de4f0be9e5f4d8d607bef6366bcfac0cd0"
},
"downloads": -1,
"filename": "s3docker-1.1.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "89cf00ae9a9e388a2fed0a50d9889ae9",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.6",
"size": 8330,
"upload_time": "2025-01-24T12:18:02",
"upload_time_iso_8601": "2025-01-24T12:18:02.158042Z",
"url": "https://files.pythonhosted.org/packages/d4/e6/63f961f522a76a86bf484ecac1bfb84f20fb55be4bcdae5614b09d8d93e1/s3docker-1.1.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "9e472d685330cb17277126960ce98ec1637ac13be642513ef93b75daf2d20876",
"md5": "faea03e1927a84afcd7cb48a926fd23b",
"sha256": "894255cca1789a291e9456aa5a5bd587de2a8196c865ff4c77481ea32ed5ab84"
},
"downloads": -1,
"filename": "s3docker-1.1.2.tar.gz",
"has_sig": false,
"md5_digest": "faea03e1927a84afcd7cb48a926fd23b",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.6",
"size": 9521,
"upload_time": "2025-01-24T12:18:04",
"upload_time_iso_8601": "2025-01-24T12:18:04.110724Z",
"url": "https://files.pythonhosted.org/packages/9e/47/2d685330cb17277126960ce98ec1637ac13be642513ef93b75daf2d20876/s3docker-1.1.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-01-24 12:18:04",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "Kawai-Senpai",
"github_project": "s3Docker",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "boto3",
"specs": [
[
"==",
"1.34.106"
]
]
},
{
"name": "docker",
"specs": [
[
"==",
"7.1.0"
]
]
},
{
"name": "click",
"specs": [
[
"==",
"8.1.8"
]
]
},
{
"name": "ultraprint",
"specs": [
[
">=",
"3.1.0"
]
]
},
{
"name": "tqdm",
"specs": [
[
">=",
"4.65.0"
]
]
},
{
"name": "halo",
"specs": [
[
">=",
"0.0.31"
]
]
}
],
"lcname": "s3docker"
}