devopsdays / devopsdays-web

This is the website for devopsdays
https://www.devopsdays.org
Other
172 stars 664 forks source link

[DISCUSSION] Improve carbon footprint of devopsdays website #14542

Open mattstratton opened 2 weeks ago

mattstratton commented 2 weeks ago

According to https://www.websitecarbon.com/website/devopsdays-org/, the devopsdays.org website is very bad on carbon emissions.

it's been requested to look into improvements.

This issue is to discuss/propose various Things We Can Do about it. Please use this issue for discussion instead of Slack, going forward!

I will link below to any prior issues, spikes, etc that are related.

mattstratton commented 2 weeks ago

One thing (not sure if it is a factor) is that a while ago, Netlify disabled image optimization (which affected how images were served and how their cache was set).

We experimented with a netlify plugin to replace this functionality, but apparently it broke production

also i just found that there is some type of Cloudinary integration available with Netlify https://www.netlify.com/integrations/cloudinary/

Netlify
Cloudinary | Netlify Integrations
Unleash the full potential of your visual media across any browser, device, and bandwidth.
mattstratton commented 2 weeks ago

here's the docs for the Cloudinary plugin for Netlify (I'm testing it on my personal website at the moment)

https://github.com/cloudinary-community/netlify-plugin-cloudinary#readme

GitHub
GitHub - cloudinary-community/netlify-plugin-cloudinary: Supercharge images on your Netlify site with Cloudinary!
Supercharge images on your Netlify site with Cloudinary! - cloudinary-community/netlify-plugin-cloudinary
mattstratton commented 2 weeks ago

Re: Cloudinary

the free plan is limited to 25,000 "transformations" (which i think basically means "image loads") per month. which is ... probably not nearly enough for us (citation needed)

the cheapest paid plan is $89/month which brings it to 225,000 transformations a month which is probably more in line. but that's NOT CHEAP

mattstratton commented 2 weeks ago

Moving to a Hugo Pipes based image processing is definitely an option to consider in order to pare down the size of images. #14341 by @toshywoshy is the first step towards this. I think we are pretty close to being able to merge that in and see if that helps! (I'll revisit the outstanding questions on that)

mattstratton commented 2 weeks ago

welp, so much for cloudinary plugin (i did a test on devopsdays-web)

image

toshywoshy commented 2 weeks ago

I think, moving to the new HugoIO CMS extended options, like image processing, header processing, style processing, minifying and refactoring code to use the newer HugoIO functions better as they have evolved over time After that we can also work on shortcodes, so standard things come with the optimal code.