Live data from Hacker News

Show HN: Dynamic image size generator

news.ycombinator.com

1–10 of 16 posts

Show HN: Dynamic image size generator

#1
Hi,

Firstly, the link to the tool - https://github.com/DrRoach/DynamicImage

I created a dynamic image sizing tool that allows images of any size to be generated on the fly. It's aims are as follows:

a) Allow users of sites to upload images of any size without the site owner having to worry about their dimensions or having to resize them.

b) Reduce load times for sites as images can be stored on their own dedicated server and be served in milliseconds.

I'd love to hear some feedback as to what you think and whether you'd consider using this tool and if not, why not?

All constructive criticism is welcome!

Re: Show HN: Dynamic image size generator

#2
I've created scripts like these as part of our home-brewed CMS system in the early 2000's.

Nice and easy dos tool. Enumerate the width and height parameters and bring down the server fast.

Better way to do it is to specify, or allow admins to specify, a set of named sizes and only allow these named sizes.

You could also think about adding parameters to determine the crop, or force aspect ratio etc. (with the same risk of dos)

Re: Show HN: Dynamic image size generator

#7

I've created scripts like these as part of our home-brewed CMS system in the early 2000's. Nice and easy dos tool. Enumerate the width and height parameters and bring down the server fast. Better way to do it is to specify, or allow admins to specify, a set of named sizes and only allow these named sizes. You could also think about adding parameters to determine the crop, or force aspect ratio etc. (with the same ris…

Having the resizing api exposed publicly lile in the ajax example is definately a bad idea.

The second example (labeled "html") demonstrates using it entirely serverside, which would be fine. That way, only the filename of the cached file is exposed.

...Which was how I did it in the late 90's.

Re: Show HN: Dynamic image size generator

#10
post #4

imgix is an image CDN service (not free) that offers this feature and more. Not usually used for personal projects I guess since there is no free tier for it.

Imgix is great, but expensive as a cdn + image size on the fly company. I have been testing then for ~6 months for thumbnail generation but will be transitioning off soon. The cost is running about half of my S3 storage and transfer bill for only generating thumbs.

It's hard to justify not just creating my own thumbnails and stashing them on S3 for my use case.

Post reply on HN