@@ -8,6 +8,7 @@ COMPOSE = $(BAZEL) run @rules_docker_compose//docker_compose --
88COMPOSE_FILE = $(abspath service/submitqueue/docker-compose.yml)
99GATEWAY_COMPOSE_FILE = $(abspath service/submitqueue/gateway/server/docker-compose.yml)
1010ORCHESTRATOR_COMPOSE_FILE = $(abspath service/submitqueue/orchestrator/server/docker-compose.yml)
11+ WEB_COMPOSE_FILE = $(abspath service/submitqueue/docker-compose.web.yml)
1112
1213# Fixed project name for local manual testing (tests use unique random names)
1314SUBMITQUEUE_LOCAL_PROJECT = submitqueue
@@ -41,6 +42,11 @@ PROTO_PACKAGES = api/base/change api/base/hook api/base/mergestrategy api/base/m
4142# Set REPO_ROOT for docker-compose
4243export REPO_ROOT := $(shell pwd)
4344
45+ # Local-only credential for the reference web host. Override it for manual
46+ # testing; production authentication is deliberately outside this demo.
47+ export SUBMITQUEUE_WEB_TOKEN ?= test
48+ export SUBMITQUEUE_WEB_CURSOR_SECRET ?= local-demo-cursor-secret
49+
4450# Which provider the demo stack targets, and the only difference between a free
4551# local run and a live one. Selects a configuration directory rather than a code
4652# path, so adding a provider is mostly adding a directory — see
@@ -148,7 +154,7 @@ define assert_clean
148154 fi
149155endef
150156
151- .PHONY: build build-all-linux build-runway-linux build-submitqueue-gateway-client build-submitqueue-gateway-linux build-submitqueue-gateway-server build-submitqueue-orchestrator-linux build-stovepipe-linux build-stovepipe-linux-debug check-gazelle check-mocks check-tidy clean clean-proto demo-requests deps docs-build docs-serve e2e-test fmt gazelle integration-test integration-test-submitqueue-consumer integration-test-extensions integration-test-submitqueue-gateway integration-test-submitqueue-orchestrator license-fix lint lint-binary lint-fmt lint-license local-init-runway-queue-schema local-init-stovepipe-schemas local-runway-start local-runway-stop local-submitqueue-stop local-submitqueue-clean local-submitqueue-gateway-start local-submitqueue-gateway-stop local-init-submitqueue-schemas local-submitqueue-logs local-submitqueue-orchestrator-start local-submitqueue-orchestrator-stop local-submitqueue-ps local-submitqueue-restart local-submitqueue-start local-stop local-stovepipe-debug-start local-stovepipe-logs local-stovepipe-start local-stovepipe-stop mocks proto query-deps query-targets run-client-runway run-client-submitqueue-gateway run-client-submitqueue-orchestrator run-client-stovepipe run-queue-admin test test-no-cache test-race tidy tidy-bazel tidy-go help
157+ .PHONY: build build-all-linux build-runway-linux build-submitqueue-gateway-client build-submitqueue-gateway-linux build-submitqueue-gateway-server build-submitqueue-orchestrator-linux build-stovepipe-linux build-stovepipe-linux-debug check-gazelle check-mocks check-tidy clean clean-proto demo-requests deps docs-build docs-serve e2e-test fmt gazelle integration-test integration-test-submitqueue-consumer integration-test-extensions integration-test-submitqueue-gateway integration-test-submitqueue-orchestrator license-fix lint lint-binary lint-fmt lint-license local-init-runway-queue-schema local-init-stovepipe-schemas local-runway-start local-runway-stop local-submitqueue-stop local-submitqueue-clean local-submitqueue-gateway-start local-submitqueue-gateway-stop local-init-submitqueue-schemas local-submitqueue-logs local-submitqueue-orchestrator-start local-submitqueue-orchestrator-stop local-submitqueue-ps local-submitqueue-restart local-submitqueue-start local-stop local-stovepipe-debug-start local-stovepipe-logs local-stovepipe-start local-stovepipe-stop mocks proto query-deps query-targets run-client-runway run-client-submitqueue-gateway run-client-submitqueue-orchestrator run-client-stovepipe run-queue-admin test test-no-cache test-race tidy tidy-bazel tidy-go web-build web-check web-e2e-test web-image-load web-install web-proto help
152158
153159
154160build : # # Build all services and examples
@@ -371,7 +377,7 @@ local-submitqueue-clean: ## Stop the stack and remove its volumes, images, and P
371377 @echo " Cleaning all services and data..."
372378 @# The overlay is named so that volumes it declares — Runway's checkouts —
373379 @# are removed too, rather than surviving as an orphan.
374- @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) down -v --rmi local
380+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) down -v --rmi local
375381 @rm -rf " $( SQ_GIT_SANDBOX_DIR) "
376382 @echo " All services, volumes, images, and $( SQ_GIT_SANDBOX_DIR) removed."
377383
@@ -460,7 +466,7 @@ local-runway-stop: ## Stop Runway service
460466 @echo " Runway services stopped."
461467
462468local-submitqueue-logs : # # View logs from all running services
463- @$(COMPOSE ) -f $(COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) logs -f
469+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $( PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) logs -f
464470
465471local-submitqueue-orchestrator-start : build-submitqueue-orchestrator-linux # # Start Orchestrator service locally (Orchestrator + 2 MySQL databases)
466472 @echo " Starting Orchestrator with docker-compose..."
@@ -484,11 +490,12 @@ local-submitqueue-orchestrator-stop: ## Stop Orchestrator service
484490local-submitqueue-ps : # # Show running containers and their ports
485491 @echo " Running containers and ports:"
486492 @echo " "
487- @$(COMPOSE ) -f $(COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) ps
493+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $( PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) ps
488494 @echo " "
489495 @echo " 📡 Service Endpoints:"
490496 @echo " Gateway gRPC: localhost:$$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -gateway-service-1 8080 2>/dev/null | cut -d: -f2 || echo 'not running')"
491497 @echo " Orchestrator gRPC: localhost:$$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -orchestrator-service-1 8080 2>/dev/null | cut -d: -f2 || echo 'not running')"
498+ @echo " Web UX: http://localhost:$$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -web-service-1 3000 2>/dev/null | cut -d: -f2 || echo 'not running')"
492499 @echo " "
493500 @echo " 🗄️ Database Endpoints:"
494501 @echo " MySQL App: localhost:$$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -mysql-app-1 3306 2>/dev/null | cut -d: -f2 || echo 'not running')"
@@ -506,11 +513,11 @@ local-submitqueue-ps: ## Show running containers and their ports
506513
507514local-submitqueue-restart : build-all-linux # # Restart all services (rebuild and restart)
508515 @echo " Restarting all services..."
509- @$(COMPOSE ) -f $(COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) restart
516+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $( PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) restart
510517 @echo " Services restarted!"
511518 @make local-submitqueue-ps
512519
513- local-submitqueue-start : build-all-linux # # Start full stack (PROVIDER=fake|git|github; github needs GITHUB_TOKEN)
520+ local-submitqueue-start : build-all-linux web-image-load # # Start full stack (PROVIDER=fake|git|github; github needs GITHUB_TOKEN)
514521 @echo " Starting full stack against provider '$( PROVIDER) ' ($( SQ_PROVIDER_CONFIG_DIR) )..."
515522 @test -f " $( SQ_PROVIDER_CONFIG_DIR) /merge.yaml" \
516523 || { echo " No such provider '$( PROVIDER) ': $( SQ_PROVIDER_CONFIG_DIR) /merge.yaml not found" ; exit 2; }
@@ -529,13 +536,16 @@ local-submitqueue-start: build-all-linux ## Start full stack (PROVIDER=fake|git|
529536 else \
530537 export SQ_CONTAINER_USER=$$(id -u ) :$$(id -g ) ; \
531538 fi ; \
532- $(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) up -d --build --wait
539+ $(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) up -d --build --wait
533540 @echo " Applying database schemas..."
534541 @$(MAKE ) -s local-init-submitqueue-schemas
535542 @echo " "
536543 @echo " ✅ Stack is running against provider '$( PROVIDER) '."
537544 @echo " "
538545 @echo " Gateway gRPC port: $$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -gateway-service-1 8080 2>/dev/null | cut -d: -f2 || echo 'unknown')"
546+ @echo " Web UX: http://localhost:$$ (docker port $( SUBMITQUEUE_LOCAL_PROJECT) -web-service-1 3000 2>/dev/null | cut -d: -f2 || echo 'unknown')"
547+ @echo " Web username: test"
548+ @echo " Web token: $( SUBMITQUEUE_WEB_TOKEN) "
539549 @if [ " $( PROVIDER) " = " git" ]; then \
540550 echo " Land target: $( SQ_GIT_SANDBOX_DIR) /sandbox.git" ; \
541551 fi
@@ -545,7 +555,7 @@ local-submitqueue-start: build-all-linux ## Start full stack (PROVIDER=fake|git|
545555
546556local-submitqueue-stop : # # Stop the SubmitQueue stack (keeps PROVIDER=git's sandbox; the databases do not survive)
547557 @echo " Stopping SubmitQueue services..."
548- @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) down
558+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $(PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) down
549559 @# Both MySQL services mount anonymous volumes, so `down` detaches them and
550560 @# the next `up` creates fresh ones. Saying "data preserved" here would be
551561 @# read as "your requests are still there", which they are not.
@@ -557,7 +567,7 @@ local-submitqueue-stop: ## Stop the SubmitQueue stack (keeps PROVIDER=git's sand
557567
558568local-stop : # # Stop every local stack — SubmitQueue, Stovepipe, and Runway
559569 @echo " Stopping all services..."
560- @$(COMPOSE ) -f $(COMPOSE_FILE ) -p $(SUBMITQUEUE_LOCAL_PROJECT ) down
570+ @$(COMPOSE ) -f $(COMPOSE_FILE ) -f $( PROVIDER_COMPOSE_FILE ) -f $( WEB_COMPOSE_FILE ) - p $(SUBMITQUEUE_LOCAL_PROJECT ) down
561571 @$(COMPOSE ) -f $(STOVEPIPE_COMPOSE_FILE ) -p $(STOVEPIPE_LOCAL_PROJECT ) down
562572 @$(COMPOSE ) -f $(RUNWAY_COMPOSE_FILE ) -p $(RUNWAY_LOCAL_PROJECT ) down
563573 @echo " Services stopped. Anonymous database volumes are not reused on the next start."
@@ -687,6 +697,28 @@ tidy-go: ## Run go mod tidy
687697 @echo " Running go mod tidy..."
688698 @$(BAZEL ) run @rules_go//go -- mod tidy -e
689699
700+ web-build : # # Build the web packages and deployable Next.js image with Bazel
701+ @$(BAZEL ) build //web/submitqueue:pkg //web/service/submitqueue:image
702+
703+ web-check : # # Run web generation, packaging, lint, type, unit, and image checks with Bazel
704+ @$(BAZEL ) test //web:check --test_output=errors
705+ @$(BAZEL ) build //web/service/submitqueue:image
706+
707+ web-e2e-test : # # Run the Bazel-managed real-stack Playwright and axe web test
708+ @$(BAZEL ) test //web/test/e2e:web_test --test_output=errors
709+
710+ web-image-load : # # Build and load the deployable web image into Docker with Bazel (also tagged with SQ_DOCKER_IMAGE_PREFIX)
711+ @$(BAZEL ) run //web/service/submitqueue:image_load
712+ @if [ -n " $$ SQ_DOCKER_IMAGE_PREFIX" ] && [ " $$ SQ_DOCKER_IMAGE_PREFIX" != " submitqueue" ]; then \
713+ docker tag submitqueue-web-service:latest " $$ SQ_DOCKER_IMAGE_PREFIX-web-service:latest" ; \
714+ fi
715+
716+ web-install : # # Install the pinned web workspace dependencies
717+ @corepack pnpm@10.17.1 --dir web install --frozen-lockfile
718+
719+ web-proto : # # Regenerate the committed TypeScript protobuf API with Bazel
720+ @$(BAZEL ) run //web/api:generate
721+
690722help : # # Show this help message
691723 @echo " Available targets:"
692724 @echo " "
0 commit comments