File tree Expand file tree Collapse file tree 1 file changed +4
-17
lines changed Expand file tree Collapse file tree 1 file changed +4
-17
lines changed Original file line number Diff line number Diff line change 1515 UNKNOWN_JSON_STR ,
1616)
1717from ads .common .extended_enum import ExtendedEnum
18- from ads .common .utils import UNKNOWN
1918
2019
2120class Usage (ExtendedEnum ):
@@ -190,22 +189,10 @@ def from_service_config(
190189 container_item .model_formats .append (
191190 additional_configurations .get ("modelFormats" )
192191 )
193-
194- # Parse environment variables from `additional_configurations`.
195- # Only keys present in the configuration will be added to the result.
196- config_keys = {
197- "MODEL_DEPLOY_PREDICT_ENDPOINT" : UNKNOWN ,
198- "MODEL_DEPLOY_HEALTH_ENDPOINT" : UNKNOWN ,
199- "PORT" : UNKNOWN ,
200- "HEALTH_CHECK_PORT" : UNKNOWN ,
201- "VLLM_USE_V1" : UNKNOWN ,
202- }
203-
204- env_vars = [
205- {key : additional_configurations .get (key , default )}
206- for key , default in config_keys .items ()
207- if key in additional_configurations
208- ]
192+ env_vars_dict = json .loads (
193+ additional_configurations .get ("env_vars" ) or "{}"
194+ )
195+ env_vars = [{key : value } for key , value in env_vars_dict .items ()]
209196
210197 # Build container spec
211198 container_item .spec = AquaContainerConfigSpec (
You can’t perform that action at this time.
0 commit comments