This updates to Node 14 (current LTS) as well as moving from Debian Stretch to
Buster for the base OS. The Debian upgrade brings along a newer Python 3.8,
which is actively supported.
When trying to build the Docker image, I kept receiving an out-of-memory
error from Webpack. This issue is apparently explained at
https://github.com/webpack/webpack/issues/1914.
Several comments in the issue suggested using Node 12 or above. Doing so
resolved this issue for me.
Signed-off-by: Matt Cengia <mattcen@mattcen.com>
When building the Docker image on amd64, canvas can be installed
from a pre-built binary. When building on an another architecture,
however, such as arm (e.g. on a Raspberry Pi), these binaries need to be
built locally, as per https://www.npmjs.com/package/canvas#compiling.
These added dependencies facilitate this. See also, issue #14400.
Signed-off-by: Matt Cengia <mattcen@mattcen.com>
`nginx:latest` is based on Debian Stretch and is listed as being 45MB,
while `nginx:alpine` is based on Alpine 3.9 and is just 7MB.
Basing the riot-web Docker image on `nginx:alpine` should
make it 38MB smaller compared to the current situation.
The nginx version seems to be "latest mainline" on both (currently 1.15.12),
judging by each Dockerfile:
- e5123eea0d/mainline/stretch/Dockerfile
- e5123eea0d/mainline/alpine/Dockerfile