Skip to content

Commit 8fb2048

Browse files
committed
Update inference service creation for connection annotation
1 parent bf23e49 commit 8fb2048

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

frontend/src/api/k8s/inferenceServices.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,9 @@ export const assembleInferenceService = (
158158
if (!isModelMesh) {
159159
predictor.minReplicas = minReplicas;
160160
predictor.maxReplicas = maxReplicas;
161+
if (imagePullSecrets) {
162+
annotations['opendatahub.io/connection'] = dataConnectionKey;
163+
}
161164
predictor.imagePullSecrets = imagePullSecrets;
162165
}
163166

@@ -173,8 +176,10 @@ export const assembleInferenceService = (
173176
delete model.storage;
174177
} else {
175178
delete model.storageUri;
179+
if (dataConnectionKey) {
180+
annotations['opendatahub.io/connection'] = dataConnectionKey;
181+
}
176182
model.storage = {
177-
key: dataConnectionKey,
178183
path,
179184
};
180185
}

0 commit comments

Comments
 (0)