From d6f39afd044940d88fbddba21754338b22eab3c7 Mon Sep 17 00:00:00 2001 From: Victor Lin <13424970+victorlin@users.noreply.github.com> Date: Tue, 28 Feb 2023 16:25:57 -0800 Subject: [PATCH] Update README for cross-compilation --- README.md | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 88ad6b9d..9a13844d 100644 --- a/README.md +++ b/README.md @@ -109,9 +109,8 @@ To push images you've built locally to Docker Hub, you can run: ./devel/copy-images -t -This will copy the `nextstrain/base:` and `nextstrain/base-builder:` -images from the local Docker registry to Docker Hub. See instructions at the top -of the script for more options. +This will copy the Nextstrain images from the local Docker registry to Docker +Hub. See instructions at the top of the script for more options. ### Adding a new software program @@ -136,12 +135,16 @@ To add a software program to `nextstrain/base`, follow steps in this order: 4. The last resort is to build from source. Look for instructions on the software's website. Add a build command to the section labeled with `Build programs from source`. Note that this can require platform-specific - instructions. + instructions. You should utilize cross-compilation tool available in the + builder stage that runs on the build platform. If possible, pin the software to a specific version. Otherwise, add the download/install/build command to the section labeled with `Add unpinned programs` to ensure the latest version is included in every Docker image build. +If possible, add the program to the builder stage that runs on the build +platform to avoid slowness that may arise from emulation. + ### Best practices The smaller the image size, the better. To this end we build upon a ["slim"