Skip to content

Commit 4c6693a

Browse files
committed
Allow in-place update for more run properties
After some testing, allow in-place update for more properties that already work out of the box: - `configuration_path` for all run types - `working_dir` and `docker` for services, triggers rolling deployment
1 parent a510369 commit 4c6693a

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

  • src/dstack/_internal/server/services

src/dstack/_internal/server/services/runs.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -912,13 +912,14 @@ def _validate_run_spec_and_set_defaults(run_spec: RunSpec):
912912
set_resources_defaults(run_spec.configuration.resources)
913913

914914

915-
_UPDATABLE_SPEC_FIELDS = ["configuration"]
915+
_UPDATABLE_SPEC_FIELDS = ["configuration_path", "configuration"]
916916
_TYPE_SPECIFIC_UPDATABLE_SPEC_FIELDS = {
917917
"service": [
918918
# rolling deployment
919919
"repo_data",
920920
"repo_code_hash",
921921
"file_archives",
922+
"working_dir",
922923
],
923924
}
924925
_CONF_UPDATABLE_FIELDS = ["priority"]
@@ -931,11 +932,13 @@ def _validate_run_spec_and_set_defaults(run_spec: RunSpec):
931932
# rolling deployment
932933
"resources",
933934
"volumes",
935+
"docker",
934936
"files",
935937
"image",
936938
"user",
937939
"privileged",
938940
"entrypoint",
941+
"working_dir",
939942
"python",
940943
"nvcc",
941944
"single_branch",

0 commit comments

Comments
 (0)