climatescape/climatescape.org

Investigate building site with GitHub actions

Closed this issue · 5 comments

Between all the development activity lately and our relatively long build times, we're hitting our Netlify build quota consistently. It's not a huge deal in the short term since it's relatively cheap to buy more minutes. In the long run though we may want to figure out a cheaper method.

One idea I had is to use GitHub actions, which are entirely free for open source projects. Netlify allows site deployments from the command line, so we could build on GitHub then deploy that way.

I think master would would work without any trouble. We could trigger upon any merge to master and a few times per day (vs the 24hr interval we trigger from Zapier today).

Deploy previews may be a problem though, and that's where we're burning the most build minutes anyway. We should investigate this further at some point.

It looks like we can publish drafts easily with the Netlify CLI tool:

https://docs.netlify.com/cli/get-started/#draft-and-production-deploys

I've just upgraded the priority of this issue as we're burning through our build quota extremely quickly. At this rate I'm projecting we'll exceed it by ~5X, incurring a monthly cost of ~$70 for builds alone.

Thought you might find these Github Action build scripts helpful. There is one for PR and one for merge to master.

https://github.com/jbolda/jacobbolda.com/tree/master/.github/workflows

Hi - did you resolve this issue?

I've been evaluating a similar Airtable + Netlify approach for a knowledge base project I'm working on and the fear of long build times has kept me from doing it. Looking at sql sync as an alternative. Any insights?

@devinbalkind we ended up not needing to as we improved out build times with caching and the velocity of builds went down after a big spike. Sorry I can't be of more help.