I do not know why, but if you try to combine both the apt-get lines, the server crashes. This works, and doesn’t cause any problems apart from being a little messier in looks, so 🤷♂️
We were generating the key in the Dockerfile, but then mounting the host’s web directory, which “obscured” (to quote the Docker docs) the directory in the container. We can move key generation to the container entrypoint, but only call it if the key doesn’t already exist to save time on container teardown / restart.