ergochat / ergo

A modern IRC server (daemon/ircd) written in Go.
https://ergo.chat/
MIT License
2.23k stars 178 forks source link

Dockerfile: `apk upgrade` before `add` #2072

Closed csmith closed 1 year ago

csmith commented 1 year ago

The base golang image ships with some packages pre-installed, but they're not necessarily the latest. If we try to add a package that (transitively) depends on one of the existing ones, it'll fail if it's expecting a newer version.

To address this, simply apk upgrade before trying to apk add.

Closes #2071

slingamn commented 1 year ago

Thanks so much!

This also works apparently: https://github.com/ergochat/ergo/commit/b4c0fcf51b0627e28b07f2db8f6df41279dfcfcc

but your strategy looks more robust.