{"id":21299032,"url":"https://github.com/ironexdev/s3-image-manager","last_synced_at":"2025-08-12T16:39:51.359Z","repository":{"id":253629203,"uuid":"843939585","full_name":"ironexdev/s3-image-manager","owner":"ironexdev","description":"AWS S3 Image Manager","archived":false,"fork":false,"pushed_at":"2024-08-29T18:29:28.000Z","size":2686,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-15T18:13:51.165Z","etag":null,"topics":["aws-s3","image-format","image-optimization","resize-image","responsive-images"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ironexdev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-17T21:59:55.000Z","updated_at":"2025-02-11T20:46:05.000Z","dependencies_parsed_at":"2024-08-29T20:31:16.902Z","dependency_job_id":null,"html_url":"https://github.com/ironexdev/s3-image-manager","commit_stats":null,"previous_names":["ironexdev/asset-uploader","ironexdev/s3-image-manager"],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/ironexdev/s3-image-manager","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ironexdev%2Fs3-image-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ironexdev%2Fs3-image-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ironexdev%2Fs3-image-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ironexdev%2Fs3-image-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ironexdev","download_url":"https://codeload.github.com/ironexdev/s3-image-manager/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ironexdev%2Fs3-image-manager/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270099197,"owners_count":24527027,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-12T02:00:09.011Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws-s3","image-format","image-optimization","resize-image","responsive-images"],"created_at":"2024-11-21T14:58:55.899Z","updated_at":"2025-08-12T16:39:51.333Z","avatar_url":"https://github.com/ironexdev.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# S3 Image Manager\n\nS3 Image Manager allows you to:\n- Optimize images with Sharp\n   - Change quality\n   - Change format\n   - Resize\n   - Clone (to create multiple versions of the same image)\n- Download processed images\n- View images stored in S3\n- Upload images to S3\n- Search images in S3\n- Delete images in S3\n\nRun it on localhost to optimize and upload images to S3. Retrieved links of uploaded images point to Cloudfront and can be used in production.\n\n## Preview\n\n### Modification\n- Change quality\n- Change format\n- Resize\n- Clone (to create multiple versions of the same image)\n\n![Modify](assets/modify.png)\n\n### Upload/Download\n- Download processed images\n- Set S3 namespace for the image\n- Upload images to S3\n\n![Upload/Download](assets/upload-download.png)\n\n### S3 for serving images\n- View images stored in S3\n- Upload images to S3\n- Search images in S3\n- Delete images in S3\n\n![S3 Server](assets/s3-server.png)\n\n## S3 for storing images\n- View images stored in S3\n- Upload images to S3\n- Search images in S3\n- Delete images in S3\n\n![S3 Storage](assets/s3-storage.png)\n\n## Pre-requisites\n\n1) Setup two AWS S3 buckets - one is for serving images (server-bucket) via Cloudfront distribution (CDN) and second is for storing raw images (storage-bucket)\n   - \u003csmall\u003eS3 bucket for storage is optional\u003c/small\u003e\n   - \u003csmall\u003eMake sure to enable versioning in your S3 buckets, otherwise you might accidentally delete your images\u003c/small\u003e\n   - \u003csmall\u003e[How to setup a Cloudfront distribution](https://www.youtube.com/watch?v=kbI7kRWAU-w)\u003c/small\u003e\n2) Create IAM user with following policy (replace \"server-bucket-name\" and \"storage-bucket-name\" with your actual bucket name)\n```\n{\n    \"Version\": \"2012-10-17\",\n    \"Statement\": [\n        {\n            \"Effect\": \"Allow\",\n            \"Action\": [\n                \"s3:GetObject\",\n                \"s3:PutObject\",\n                \"s3:DeleteObject\",\n                \"s3:ListBucket\"\n            ],\n            \"Resource\": [\n                \"arn:aws:s3:::server-bucket-name\",\n                \"arn:aws:s3:::server-bucket-name/*\",\n                \"arn:aws:s3:::storage-bucket-name/*\",\n                \"arn:aws:s3:::storage-bucket-name/*\"\n            ]\n        }\n    ]\n}\n```\n\n## How to setup\n1) Download or git clone this repo\n2) Create .env file based on .env.example and place it in the root of the project\n    - The region needs to be us-east-1 for Cloudfront to work (Cloudfront is a global service, but according to AWS it has to be configured in us-east-1)\n3) Run `npm run install` or `yarn install` or `pnpm install` (I use pnpm, but other package managers should work too)\n4) Run `npm run dev` or `yarn dev` or `pnpm dev` to start the server\n5) Open your browser and go to `http://localhost:3010`\n\n## How to use\n1) **Run it on localhost:3010**\n2) **Modify images** \u003csmall\u003e(change quality, format, resize, clone)\u003c/small\u003e\n3) **Upload images to S3** \u003csmall\u003e(set S3 namespace for the image)\u003c/small\u003e\n4) **Download processed images**\n5) **Manage images in S3**\n   - View images stored in S3\n   - Search images in S3\n   - Delete images in S3\n\n## Notes\n- Animations / GIFs are not supported\n   aws s3api delete-objects --bucket blazing-peon-images --delete \"$(aws s3api list-object-versions --bucket blazing-peon-images --query='{Objects: Versions[].{Key:Key,VersionId:VersionId}}')\" --output=json\n- Fun command to **delete all objects in a bucket permanently**, including versions - I suggest you don't use this a\n   - `aws s3api delete-objects --bucket \u003creplace-this-with-bucket-name\u003e --delete \"$(aws s3api list-object-versions --bucket \u003creplace-this-with-bucket-name\u003e --query='{Objects: Versions[].{Key:Key,VersionId:VersionId}}')\" --output=json \u003e /dev/null 2\u003e\u00261`","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fironexdev%2Fs3-image-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fironexdev%2Fs3-image-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fironexdev%2Fs3-image-manager/lists"}