Pretty cool idea! We did something similar when we launched ads on Read the Docs, which we call Community Ads: https://docs.readthedocs.io/en/stable/advertising/ethical-ad...
Basically, we show ads for OSS projects & conferences in the ad spot on a small percentage of our traffic. It's a nice way to give back, and in the past we've shown ads for many Pycon's around the world, the PSF's annual fundraiser, and a bunch more worthwhile community projects.
The hardest thing has actually been finding projects that are well targeted for our community, and getting design assets for them. A lot of OSS & side projects don't have this stuff, and the ones who do probably don't need much promotion.