Skip to content

fix(infra): training image ENTRYPOINT; document build-branch and pref… - #31

Merged
Enskc05 merged 1 commit into
mainfrom
devops/fix
Aug 7, 2026
Merged

Enskc05 merged 1 commit into
mainfrom
devops/fix

Conversation

@Enskc05

@Enskc05 Enskc05 commented Aug 7, 2026

Copy link
Copy Markdown
Collaborator

fix(infra): training image ENTRYPOINT; document build-branch and prefix traps

Follow-up to #30. The first smoke test on the server hit three blockers; all
three are closed here.

1. CMD → ENTRYPOINT

Kubernetes args replace a container's CMD, but are appended to its
ENTRYPOINT. With the training command in CMD, a Job that passes only Hydra
overrides as args made the runtime try to execute the override itself:

StartError: exec: "training.epochs=1": executable file not found in $PATH

Moving the command to ENTRYPOINT makes args behave as intended. The example
manifest now carries an explicit "do not set command" note, since setting it
would override the entrypoint and silently drop every Hydra override.

2. Build can silently use the wrong branch

The training code lives on ml/feature while the Dockerfile lives on main,
so the build overlays three files from main onto an ml/feature checkout.
If the file list is dropped from that second checkout, git checkout origin/main switches the entire tree to main — the build then succeeds
against main's services/ml, and the failure only surfaces at run time:

No module named services.ml.training.train

This is easy to miss because requirements/ml.txt looks correct either way
(#30 added the missing packages to main). The runbook now includes a
pre-build verification step that checks for files which only exist on
ml/feature.

3. MinIO prefix mismatch — confirmed

services/ml/conf/data/default.yaml sets bucket_name: datasets and
minio_prefix: datasets/training-512/v1. The actual layout on the server:

$ mc ls dh/datasets/training-512/v1/
clean/ degraded/

So the prefix should be training-512/v1; as configured, boto3 looks for
datasets/datasets/training-512/v1 and finds nothing. The permanent fix
belongs to the ML squad — until then, runs need
data.minio_prefix=training-512/v1 as an override, which the runbook now
documents.

Testing

Image builds clean and the dependency verification step passes
(torch 2.6.0+cu124 | cuda 12.4 | numpy 2.2.2). The container starts and
imports resolve inside the cluster. End-to-end training smoke test is running
against the rebuilt image; results to follow.

…ix traps

Smoke test sunucuda uc engele takildi, ucu de burada kapatiliyor.

1. CMD -> ENTRYPOINT. Kubernetes'te manifest'e yazilan `args` CMD'nin YERINE
   gecer; pod "exec: training.epochs=1: executable file not found" ile
   StartError'a dusuyordu. ENTRYPOINT'te args komutun sonuna eklenir, yani
   Hydra override'lari amaclandigi gibi calisir. Ornek manifest'e de
   "command yazma" notu eklendi.

2. Build daldan yanlis alinabiliyor. `git checkout origin/main` (dosya
   listesi olmadan) tum agaci main'e ceviriyor ve imaj sessizce main'in
   services/ml'iyle olusuyor; ilk kosu "No module named
   services.ml.training.train" ile duser. Runbook'a checkout dogrulamasi
   eklendi.

3. MinIO prefix'i dogrulandi: gercek yol datasets bucket + training-512/v1.
   conf/data/default.yaml prefix'i "datasets/training-512/v1" diyor, yani
   boto3 datasets/datasets/... arar. Kalici duzeltme ML squad'da; o gelene
   kadar kosulara data.minio_prefix override'i eklenmeli.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@Enskc05
Enskc05 merged commit 7e916be into main Aug 7, 2026
0 of 2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant