Ask HN: Where do you host images for your blog or landing pages?
35 points| akshaykumar90 | 3 years ago | reply
Currently, I am using Cloudinary but the management interface leaves a lot to be desired. I have seen some static sites use GitHub repositories for hosting images which I think is a pretty cool hack.
[+] [-] mattw2121|3 years ago|reply
[+] [-] mdasen|3 years ago|reply
I used to upload assets for apps to S3 to be served from there when I just started thinking that my CDN is going to be taking the vast majority of hits for static files so why should I be adding a step to my deploy process?
[+] [-] bombcar|3 years ago|reply
[+] [-] marginalia_nu|3 years ago|reply
If you're really worried, cloudflare can help with caching. FWIW, this is served off domestic broadband with cloudflare caching: https://search.marginalia.nu/explore/random It's survived the HN front-page, despite being a bit of a pathological case since the images are random out of a pool of tens of thousands. Images are also larger than they appear visually. Native res is like this: https://search.marginalia.nu/screenshot/187889
[+] [-] chrismorgan|3 years ago|reply
[+] [-] gh123man|3 years ago|reply
[+] [-] bradley_taunt|3 years ago|reply
Turns that $5/month to less than $3/month for low traffic sites.
[+] [-] sofixa|3 years ago|reply
[+] [-] kingsloi|3 years ago|reply
[+] [-] Ptchd|3 years ago|reply
[+] [-] colbyfayock|3 years ago|reply
If you're on the Netlify side of things, I have a plugin there that automates images https://github.com/colbyfayock/netlify-plugin-cloudinary/
There's a ton others too: https://cloudinary.com/documentation/cms_ecommerce_integrati... https://cloudinary.com/documentation/partner_built
Hope that helps, happy to brainstorm other ideas as well!
[+] [-] janeway|3 years ago|reply
[+] [-] pocketsand|3 years ago|reply
Alternatively, as others have said, you can just plop them on the server and call it a day.
[+] [-] 0xbadcafebee|3 years ago|reply
[+] [-] 0xbadcafebee|3 years ago|reply
CloudFlare Pages (https://pages.cloudflare.com/) has a free plan with 100 sites, unlimited requests, unlimited bandwidth. Maximum file size 25MB, 20,000 files, 100 domains, 100 custom headers, 2,000 static redirects, 100 dynamic redirects. (https://developers.cloudflare.com/pages/platform/limits/) Unknown if there's a commercial restriction.
[+] [-] TrueGeek|3 years ago|reply
[+] [-] brycewray|3 years ago|reply
[+] [-] cheptsov|3 years ago|reply
For example, we use GitHub Pages for hosting the landing page. So for hosting images, we use GitHub itself and it mostly works.
For the blog, we currently use Substack, but thinking of maybe moving it to GitHub Pages too.
FYI, here is our repo: https://github.com/dstackai/dstack
[+] [-] jasode|3 years ago|reply
Maybe recalibrate the suggestions based on the above. (Or the submitter can further clarify why hosting local image assets instead of using a CDN is not feasible in his particular case so the crowdsourced answers can be more productive to his goals.)
EDIT add: Sure, obvious technical answer may be applicable but some replies have a bit of condescension that doesn't seem appropriate and respectful of this person's tech background.
[+] [-] uptown|3 years ago|reply
[+] [-] dewey|3 years ago|reply
[+] [-] akshaykumar90|3 years ago|reply
[+] [-] subpixel|3 years ago|reply
https://github.com/toolinbox/iPic
[+] [-] Archelaos|3 years ago|reply
[+] [-] beemaestro|3 years ago|reply
[+] [-] tyingq|3 years ago|reply
I don't know the current state of doing this, but it has been problematic in the past because they don't return the right content-type headers.
[+] [-] Apreche|3 years ago|reply
Some files are files that are part of the web site. They are put there by the developer(s) of the web site. Things like maybe the logo image in the header, or that cool rotating flaming skull in the footer. These files just go on the file system of the web server.
Some files are user uploads. A person writing a blog post wants to upload some images to be inserted into that blog post. For these sorts of files I just use whatever object storage system makes the most sense given the circumstances S3, GCS, etc.
[+] [-] madmax108|3 years ago|reply
I use this way more often than I should TBH. YMMV
Note: Only do this for images you have backed up elsewhere (heck, in git itself is fine). This is purely to prevent having to spend any $$$ on hosting/CDN whatever
[+] [-] ianpurton|3 years ago|reply
I use Zola the static site generator. My repo is here https://github.com/purton-tech/cloak/tree/main/www
[+] [-] D13Fd|3 years ago|reply
My hosting provider (Render) requires an add-on for file storage, so last I checked AWS S3 free tier was the cheaper option.
[+] [-] HHalvi|3 years ago|reply