dbb8f6e006713f43b7dbd6100d3b5c024dc72766 braney Fri Sep 18 11:11:15 2026 -0700 weeklybld: let the docker instance scripts run a past release, refs #38377 We could not reproduce a bug against the release a user is actually on. hgwdev runs tip and the current release, and nothing older. Docker Hub already has a per-release image, so the missing piece was a way to run one. The lifecycle scripts now take a release name as well as tip, beta and rel. run-instance.sh v503 starts the published v503 image as container kent-v503 on port 8503; the port is 8000 plus the release number, so the mapping needs no table and no allocator. A release instance gets no CGI overlay, for the same reason rel gets none: it has to be the code that shipped. refresh-instance.sh, remove-instance.sh and smoke-instance.sh take the same name. smoke-instance.sh checks a release instance against the version in its own name, so no --version flag is needed. start-all.sh and stop-all.sh now read the release containers that exist rather than a fixed list, so the set of releases we keep can change without editing them. tunnel-release.sh is one script for every release rather than one per release, since that set changes. v499 through v503 are running on hgwdev on ports 8499 through 8503 and pass smoke-instance.sh. Five instances cost about 1.5 GB of memory, 10 GB of docker disk, and no measurable CPU. They read tables from genome-mysql.soe.ucsc.edu and files from hgdownload.soe.ucsc.edu, so they put no load on the hgwdev MySQL or /gbdb. diff --git src/utils/qa/weeklybld/smoke-instance.sh src/utils/qa/weeklybld/smoke-instance.sh index f4f62270ad3..374ddeb8818 100755 --- src/utils/qa/weeklybld/smoke-instance.sh +++ src/utils/qa/weeklybld/smoke-instance.sh @@ -1,60 +1,64 @@ #!/bin/bash # -# smoke-instance.sh [tip|beta|beta-arm64|rel ...] [--version NN] +# smoke-instance.sh [tip|beta|beta-arm64|rel|vNNN ...] [--version NN] # # Quick smoke test of one or more docker browser QA instances on hgwdev. With no # instance arguments it tests the two beta instances (beta + beta-arm64) -- the # ones a weekly build stands up at do_final. Name one or more instances to test # just those. # # For each instance it checks, over the instance's loopback port, that: # - the kent- container is running, # - hgGateway serves the gateway page, # - hgTracks renders a real image for hg38 AND hg19 -- the drawn PNG plus the # expected track names prove Apache + the CGI + MariaDB + trackDb all work # end to end (a bare HTTP 200 does not: CGI error dumps are 200 too, so we # also assert the page is NOT a UCSC HGERROR / "Very Early Error" page), # - hgBlat and hgTables load, # - and it reports the CGI version parsed from the hgTracks title. Pass # --version NN (e.g. --version 501) to make a version mismatch a failure. +# A release instance names its own version, so kent-v503 is checked against +# v503 with no --version needed. refs #38377 # # Exit status is 0 only if every check on every instance passed. refs #37655 # set -u # ---- args ------------------------------------------------------------------- want_version="" instances=() while [[ $# -gt 0 ]]; do case "$1" in --version|-v) want_version="${2:?--version needs a number}"; shift 2 ;; - tip|beta|beta-arm64|rel) instances+=("$1"); shift ;; + tip|beta|beta-arm64|rel|v[0-9][0-9][0-9]) instances+=("$1"); shift ;; -h|--help) - echo "usage: $(basename "$0") [tip|beta|beta-arm64|rel ...] [--version NN]" >&2 + echo "usage: $(basename "$0") [tip|beta|beta-arm64|rel|vNNN ...] [--version NN]" >&2 exit 1 ;; *) echo "unknown argument: $1" >&2; exit 1 ;; esac done [[ ${#instances[@]} -eq 0 ]] && instances=(beta beta-arm64) port_of() { case "$1" in tip) echo 8081 ;; beta) echo 8082 ;; rel) echo 8083 ;; beta-arm64) echo 8084 ;; + # a release instance's port encodes the release, as in run-instance.sh + v[0-9][0-9][0-9]) echo $(( 8000 + 10#${1#v} )) ;; esac } # generous timeout: the arm64 instance runs emulated (QEMU) and is slow. CURL="curl -s -m 90" overall=0 # check