weaveworks / service

☁️ Images for Weave Cloud (R) (TM) (C) ☁️
https://cloud.weave.works
2 stars 2 forks source link

Upgrade golang to 1.17 #2729

Closed ozamosi closed 2 years ago

ozamosi commented 2 years ago

First, stop using the golang build base image - a rolling stable, has-everything-in-it base image is an antipattern that always leads to being unable to upgrade anything (because if I change the base image version, I'll break repos I don't even know exists). And what we're doing is even worse, where the name of the image isn't actually a release but a branch name that has since been merged into master. This thus copies the setup steps into the service build image - except terraform, I have no use for terraform here.

That lets me specify a recent version of go.

That forces me to specify that we don't use go modules. Of course, it would be splendid to start usin g modules while I'm at it, but I've spent a full workday on this already: we use a tonne of weird, very-specific non-master or non-released versions of things that happened to be locked in 2017 or so and hasn't been updated since, porting them isn't always obvious, and even after pinning those versions again after migrating, we also do some weird codecgen inside the vendored scope repo using a manually compiled binary from another vendored repo, and I just can't get it to work.