Repository navigation
ci(integration): generate viewer .dat on a kind cluster - #594
Open
gjedlicska wants to merge 2 commits into
Open
gjedlicska wants to merge 2 commits into
gjedlicska wants to merge 2 commits into
Conversation
The next speckle-server:latest (job system) has no Docker stand-in: it launches .dat generation as Kubernetes Jobs through JOB_SYSTEM_KUBECONFIG. scripts/integration-cluster.sh, shared by CI and local runs, creates a single-node kind cluster (node labelled purpose=conversion, namespace conversion), loads the converter image into it and exports the internal kubeconfig the server container mounts from the kind network. Job pods and the host-side tests consume the same presigned S3 URLs, so S3_PUBLIC_ENDPOINT and PRIVATE_OBJECTS_SERVER_URL point at the kind network gateway (host.docker.internal on Docker Desktop), where garage is now published. The socket mount, group_add and CONVERSION_RUNNER_LOCAL_DEV stay until a server latest without the stand-in is published, so today's latest keeps generating .dat files.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #594 +/- ##
==========================================
- Coverage 75.71% 75.71% -0.01%
==========================================
Files 483 483
Lines 27028 27028
Branches 2724 2724
==========================================
- Hits 20464 20463 -1
Misses 5586 5586
- Partials 978 979 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…L_INGESTION_DAT_GENERATION_*) The server's ENG-10148 renamed the pool and per-kind env vars. Without JOB_SYSTEM_IMAGE_PULL_POLICY=IfNotPresent a :latest converter defaults to Always and the kubelet tries to pull the private image the node does not have credentials for.
gjedlicska
force-pushed
the
gergo/integration-dat-generation-on-kind
branch
from
October 1, 2026 10:12
0ffe21a to
3c7096f
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
The internal integration job gets viewer-
.datgeneration from speckle-server's Docker stand-in (CONVERSION_RUNNER_LOCAL_DEV): the server runs the converter image through the mounted Docker socket. The nextspeckle-server:latest(the job-system branch,feat/job-system) drops the stand-in. Its only off-cluster backend is a real cluster reached throughJOB_SYSTEM_KUBECONFIG. Without a cluster, that server cannot generate.datfiles under compose.What
scripts/integration-cluster.sh: one script for CI and local runs.up(idempotent): creates a single-node kind cluster,speckle-sdk-integrationby default (KIND_CLUSTER_NAMEoverrides it). The node is labelledpurpose=conversion, the namespace isconversion, and the node image is pinned by digest to kind v0.31.0's default. It writeskind get kubeconfig --internalto the gitignored.kind/kubeconfig.load-image: loads the converter image into the node.env: prints the compose interpolation values.check: a pod proves it can reach the server and garage.status: dumps Jobs, pods and events.down: deletes the cluster.~/.kube/config.docker-compose-internal.yml:speckle-serverjoins the externalkindnetwork. It mounts the internal kubeconfig withcreate_host_path: false, so a missing file fails loudly.JOB_SYSTEM_KUBECONFIG,CONVERSION_JOB_NAMESPACE,CONVERSION_NODE_POOL,CONVERSION_IMAGE_PULL_POLICY=IfNotPresentandFILEIMPORT_SERVICE_USE_PRIVATE_OBJECTS_SERVER_URL+PRIVATE_OBJECTS_SERVER_URL.DATGEN_BASE_MEMORY_MIBdrops to 1024. Requests are hard reservations on the one node that the stack and the test run share, and an OOM still climbs the ×2 ladder.S3_PUBLIC_ENDPOINTandPRIVATE_OBJECTS_SERVER_URLuse${KIND_HOST_ADDRESS}. That is thekindnetwork gateway on Linux, orhost.docker.internalon Docker Desktop. Presigned upload URLs embedS3_PUBLIC_ENDPOINT, and Job pods and the host-side C# tests consume the same URLs, so one address has to work from both sides.${KIND_PUBLISH_ADDRESS}(the gateway, or127.0.0.1on Docker Desktop). The server keeps0.0.0.0:3000.:?-required, so compose fails with a pointer to the script instead of silently misrouting.integration-test.ymlfor the internal image only, and the callable workflow):helm/kind-action@v1(install_only);upand appendenvto$GITHUB_ENVbefore the background pulls;load-imageit;Transition and when to drop it
Today's
speckle-server:latest(servermain) knows onlyCONVERSION_RUNNER_LOCAL_DEVand ignoresJOB_SYSTEM_KUBECONFIG. The next one ignoresCONVERSION_RUNNER_LOCAL_DEV. Both sets of settings stay in for now: the socket mount,group_addandCONVERSION_RUNNER_LOCAL_DEV, plus the new kind settings. That way.datgeneration works with either image. Drop the socket mount,group_add,DOCKER_GIDandCONVERSION_RUNNER_LOCAL_DEVonce aspeckle-server:latestwithout the stand-in is published. A comment in the compose file says the same.The old stand-in still works with the new addresses:
SERVER_URLhosts. The gateway URLs pass through unchanged, and a host-networked container reaches a gateway-published port (smoke below).bundle-migration-servicereaches the gateway S3 URLs the same way.kind loadneeds too.Local flow
This is in the README:
Obsolete branch
gergo/job-system-local-dev-env(addsJOB_SYSTEM_LOCAL_DEV) is obsolete: that switch never ships, because the job system's only off-cluster backend is the kind cluster. This PR does not touch that branch; it can be closed.Server side after merge
speckle-server-internal's.github/workflows/manual-trigger-sharp-sdk-integration-tests.ymlpins this callable workflow atb278c769…(Aug 2026), but it checks out the SDK atspeckle-sharp-sdk-ref: 'main'. After this merges, the pinned workflow would run with the new compose file and no kind cluster, so compose fails on the missingKIND_*variables. The pin must be bumped to this PR's merge commit.Smoke (local, throwaway cluster
sdk-kind-smoke, deleted afterwards)KIND_CLUSTER_NAME=sdk-kind-smoke ./scripts/integration-cluster.sh up:namespace/conversion created, exit 0;cluster sdk-kind-smoke already exists/namespace/conversion unchanged;get nodes -L purposeshowedPURPOSE conversion;server:ishttps://sdk-kind-smoke-control-plane:6443, mode-rw-r--r--;~/.kube/configwas untouched.envprintedKIND_HOST_ADDRESS=172.19.0.1/KIND_PUBLISH_ADDRESS=172.19.0.1.docker compose -f docker-compose-internal.yml config:host_ip: 172.19.0.1,S3_PUBLIC_ENDPOINT: http://172.19.0.1:9000,PRIVATE_OBJECTS_SERVER_URL: http://172.19.0.1:3000, the kubeconfig bind andkind: external: true.required variable KIND_PUBLISH_ADDRESS is missing a value: run scripts/integration-cluster.sh up, then export its env.--env-file .kind/compose.envform also validates.docker run --rm --network kind --user 65532:65532 -v .kind/kubeconfig:/kind/kubeconfig:ro registry.k8s.io/kubectl:v1.35.0 --kubeconfig /kind/kubeconfig get nslistedconversion,default,kube-*andlocal-path-storage. It ran under the server image's uid.busybox httpdon its own docker network, published on172.19.0.1:18090(the same shape as garage), was reached from all three places, each printinghello-from-gateway-publish:purpose=conversion(wget);curl);--network hostcontainer (the old stand-in's mode).checkcorrectly reportedFAIL … server at 172.19.0.1:3000(nothing listening) andok … garage at 172.19.0.1:9000, then exited 1.load-imagewith a small image landed in the node'scrictl images.downdeleted the cluster.Not run locally: the full compose stack and the C# suite. Ports 9000 and 6379 on this machine are held by another dev stack. This PR's CI is the end-to-end check.