mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-08-31 01:02:04 +08:00
Add smoke test to verify client build is served
Adds a check in the container image CI workflow to verify that /static/dist/base.css can be fetched from the deployed Galaxy instance. This catches issues where the client build is not properly included in the Docker image, which would result in 404 errors for static files. Also removes the redundant second COPY statement in the Dockerfile. In the original multi-stage build, the second COPY was needed to bring in static files from the client_build stage. In the simplified single-stage build, the first COPY already includes everything from stage1, making the second COPY redundant. See: https://github.com/galaxyproject/galaxy/pull/21695 https://claude.ai/code/session_01MUPhw6AEjCXdWutLRgu6Hz
This commit is contained in:
@@ -227,6 +227,19 @@ jobs:
|
||||
if [ "$appVersion" != "$apiVersion" ]; then
|
||||
exit 1
|
||||
fi
|
||||
- name: Check client build is served
|
||||
run: |
|
||||
base_url=$(kubectl get svc -n galaxy galaxy-nginx -o jsonpath="http://{.spec.clusterIP}:{.spec.ports[0].port}")
|
||||
css_url="${base_url}/galaxy/static/dist/base.css"
|
||||
echo "Checking client build at $css_url"
|
||||
status_code=$(curl -s -o /dev/null -w "%{http_code}" "$css_url")
|
||||
echo "Status code: $status_code"
|
||||
if [ "$status_code" != "200" ]; then
|
||||
echo "ERROR: Failed to fetch base.css (status: $status_code)"
|
||||
echo "This indicates the client build was not properly included in the image"
|
||||
exit 1
|
||||
fi
|
||||
echo "Client build is properly served"
|
||||
|
||||
pr:
|
||||
name: Create a PR to update the Galaxy Helm chart when a release is tagged
|
||||
|
||||
@@ -148,7 +148,6 @@ WORKDIR $ROOT_DIR
|
||||
# Copy galaxy files to final image
|
||||
# The chown value MUST be hardcoded (see https://github.com/moby/moby/issues/35018)
|
||||
COPY --chown=$GALAXY_USER:$GALAXY_USER --from=stage1 $ROOT_DIR .
|
||||
COPY --chown=$GALAXY_USER:$GALAXY_USER --from=stage1 $SERVER_DIR/static ./server/static
|
||||
|
||||
WORKDIR $SERVER_DIR
|
||||
|
||||
|
||||
Reference in New Issue
Block a user