neondatabase / autoscaling

Postgres vertical autoscaling in k8s
Apache License 2.0
142 stars 16 forks source link

Use go-chef for image builds #989

Open sharnoff opened 2 weeks ago

sharnoff commented 2 weeks ago

It dramatically reduces the amount of time it takes to re-run image building if the set of packages used hasn't changed. It's hard to get an objective measurement (because we do get some caching from being careful what we add), but:

On my machine, for a rebuild after a change in 'pkg/api', it reduces make docker-build time from 249s -> 22s.

And, it also slightly improves the time it takes to run a clean build. After docker system prune -af, it reduces make docker-build on my machine from 345s -> 126s.


I'm not super enthusiastic about this particular arrangement, because we need to make sure that all the dockerfiles exactly match at the top, but maybe it's ok for now?

Also, this change affects our image building for other platforms, I think? It was inconsistent between neonvm components and the others anyways though, so I'm not entirely sure it matters.

sharnoff commented 2 weeks ago

Another fun datapoint: Seems like it may drop clean image builds in CI from ~2m50s → ~1m45s