msdev 0.10.1__tar.gz → 0.12.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {msdev-0.10.1 → msdev-0.12.0}/PKG-INFO +65 -55
- {msdev-0.10.1 → msdev-0.12.0}/README.md +64 -54
- {msdev-0.10.1 → msdev-0.12.0}/pyproject.toml +2 -2
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/__init__.py +1 -1
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/cli.py +118 -511
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/compat.py +40 -0
- msdev-0.12.0/src/msdev/core/daemon_deploy.py +49 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/env_transfer.py +42 -8
- msdev-0.12.0/src/msdev/core/exec_argv.py +82 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/resources.py +58 -11
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/context.py +1 -1
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/environment.py +18 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/execution.py +8 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/node.py +45 -3
- msdev-0.12.0/src/msdev/core/ssh_auth.py +395 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/ssh_tunnel.py +7 -1
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/stream_transport.py +13 -3
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/transport.py +362 -155
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/daemon.py +103 -1
- msdev-0.12.0/src/msdev/helpers/msdev-file-helper-linux-amd64 +0 -0
- msdev-0.12.0/src/msdev/helpers/msdev-file-helper-linux-amd64.sha256 +1 -0
- msdev-0.12.0/src/msdev/helpers/msdev-file-helper-linux-arm64 +0 -0
- msdev-0.12.0/src/msdev/helpers/msdev-file-helper-linux-arm64.sha256 +1 -0
- msdev-0.12.0/src/msdev/helpers/msdevd-linux-amd64 +0 -0
- msdev-0.12.0/src/msdev/helpers/msdevd-linux-amd64.sha256 +1 -0
- msdev-0.12.0/src/msdev/helpers/msdevd-linux-arm64 +0 -0
- msdev-0.12.0/src/msdev/helpers/msdevd-linux-arm64.sha256 +1 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev.egg-info/PKG-INFO +65 -55
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev.egg-info/SOURCES.txt +16 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_cli.py +42 -67
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_cli_only_architecture.py +10 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_compat.py +19 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_config.py +1 -1
- msdev-0.12.0/tests/test_connect_env_scenario.py +146 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_daemon.py +24 -0
- msdev-0.12.0/tests/test_daemon_deploy.py +143 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_env_transfer.py +27 -0
- msdev-0.12.0/tests/test_exec_argv.py +55 -0
- msdev-0.12.0/tests/test_go_msdevd_scenario.py +209 -0
- msdev-0.12.0/tests/test_model_cli.py +19 -0
- msdev-0.12.0/tests/test_msdev_cli_skill.py +72 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_node_env_config.py +1 -1
- msdev-0.12.0/tests/test_ssh_auth.py +515 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_target_exec_services.py +90 -5
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_transport.py +55 -18
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_windows_local_scenario.py +42 -0
- msdev-0.10.1/tests/test_model_cli.py +0 -364
- msdev-0.10.1/tests/test_msdev_cli_skill.py +0 -107
- {msdev-0.10.1 → msdev-0.12.0}/LICENSE +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/setup.cfg +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/__init__.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/config.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/container_helper.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/guides.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/helper_deploy.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/host_files.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/host_mutations.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/inventory.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/limits.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/local_rpc.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/multiplex.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/request_client.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/__init__.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/capabilities.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/model.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/npu.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/services/results.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/stream_limits.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/stream_server.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev/core/streamproto.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev.egg-info/dependency_links.txt +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev.egg-info/entry_points.txt +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/src/msdev.egg-info/top_level.txt +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_container_helper.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_daemon_container_stream.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_docker_stream_dispatch.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_env_put_get_scenario.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_env_read_write_scenario.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_exec_default_timeout_scenario.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_helper_deploy.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_inventory.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_model_services.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_multiplex.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_node_env_services.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_request_client.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_ssh_tunnel.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_stream_server.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_stream_transport.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_streamproto.py +0 -0
- {msdev-0.10.1 → msdev-0.12.0}/tests/test_target_guides.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: msdev
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.12.0
|
|
4
4
|
Summary: Portable nodes and execution environments for msModelSlim development
|
|
5
5
|
Author: msModelSlim Agent Contributors
|
|
6
6
|
License-Expression: MulanPSL-2.0
|
|
@@ -25,16 +25,15 @@ Dynamic: license-file
|
|
|
25
25
|
|
|
26
26
|
# msdev
|
|
27
27
|
|
|
28
|
-
`msdev`
|
|
29
|
-
|
|
30
|
-
optional conda/venv/uv layers.
|
|
28
|
+
`msdev` exposes three capabilities: **`node`** (connect + host agent),
|
|
29
|
+
**`env`** (shared execution context, shell, files), and **`exec`** (commands).
|
|
31
30
|
|
|
32
|
-
|
|
31
|
+
A Node owns SSH reachability and `msdevd` deployment. An Env owns the full
|
|
32
|
+
execution context: host or Docker runtime, conda/venv/uv layers, optional
|
|
33
|
+
`setup` script (root switch, proxy, etc.), command `wrap`, and static env vars.
|
|
33
34
|
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
- no harness conversation binding or implicit current Env exists;
|
|
37
|
-
- MCP is not part of the architecture.
|
|
35
|
+
The CLI is intentionally stateless: execution always names `--env` explicitly.
|
|
36
|
+
MCP is not part of the architecture.
|
|
38
37
|
|
|
39
38
|
## Install
|
|
40
39
|
|
|
@@ -62,6 +61,12 @@ implement ControlMaster multiplexing, so msdev:
|
|
|
62
61
|
`env put`/`get` stay on scp/ssh streams (file bytes do not go through JSON RPC);
|
|
63
62
|
- hides SSH console windows (`CREATE_NO_WINDOW`) and kills process trees with
|
|
64
63
|
`taskkill /T` on timeout or cancel;
|
|
64
|
+
- SSH is non-interactive: `BatchMode` unless a password is supplied, host keys
|
|
65
|
+
use `accept-new`, and there is no password/passphrase/yes-no prompt. When a
|
|
66
|
+
password is known, injects OpenSSH `SSH_ASKPASS` so `node connect` (and later
|
|
67
|
+
ssh/scp) can authenticate without a TTY; the local public key is then
|
|
68
|
+
installed on the Node so later logins are passwordless. The password is
|
|
69
|
+
never written to the node registry;
|
|
65
70
|
- serves a TCP loopback endpoint for local `msdevd` when this Python build has
|
|
66
71
|
no `AF_UNIX` sockets.
|
|
67
72
|
|
|
@@ -85,17 +90,44 @@ msdev node list
|
|
|
85
90
|
msdev node status dev-122
|
|
86
91
|
```
|
|
87
92
|
|
|
88
|
-
Adding a Node atomically creates a same-named host Env.
|
|
89
|
-
the remote
|
|
93
|
+
Adding a Node atomically creates a same-named host Env. Connect deploys and
|
|
94
|
+
starts the remote `msdevd` when needed:
|
|
90
95
|
|
|
91
96
|
```bash
|
|
92
|
-
msdev node
|
|
97
|
+
msdev node connect dev-122
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
Connect uploads a **static Go msdevd** binary matching the node architecture
|
|
101
|
+
(`linux-amd64` / `linux-arm64`) when the agent is missing or stale. No Python
|
|
102
|
+
is required on the node.
|
|
103
|
+
|
|
104
|
+
Build the static daemons before release or local testing:
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
bash msdevd/build-static.sh
|
|
108
|
+
bash file-helper/build-static.sh
|
|
93
109
|
```
|
|
94
110
|
|
|
95
|
-
|
|
111
|
+
Packaged artifacts live under `src/msdev/helpers/` (gitignored until built).
|
|
112
|
+
The Go source is in `msdev/`.
|
|
113
|
+
|
|
114
|
+
Persistent OpenSSH masters are optional. All SSH from msdev is
|
|
115
|
+
non-interactive: host keys use `accept-new`, and password/passphrase prompts
|
|
116
|
+
are disabled. Supply a password via environment or file (never a prompt);
|
|
117
|
+
connect then installs the local public key (`~/.ssh/id_ed25519`, generated
|
|
118
|
+
if missing) so later connections are passwordless:
|
|
96
119
|
|
|
97
120
|
```bash
|
|
121
|
+
# Environment (also used by exec / env put after connect if persist is off)
|
|
122
|
+
export MSDEV_SSH_PASSWORD='...'
|
|
123
|
+
export MSDEV_SSH_PASSWORD_DEV_122='...' # per-node override
|
|
124
|
+
|
|
98
125
|
msdev node connect dev-122
|
|
126
|
+
msdev node connect dev-122 --password-file FILE
|
|
127
|
+
msdev node connect dev-122 --password-env VAR
|
|
128
|
+
msdev node connect dev-122 --password PASSWORD # non-interactive; visible in ps
|
|
129
|
+
msdev node connect dev-122 --identity FILE # choose which key to install
|
|
130
|
+
msdev node connect dev-122 --no-install-key # password only, do not copy key
|
|
99
131
|
msdev node disconnect dev-122
|
|
100
132
|
```
|
|
101
133
|
|
|
@@ -109,8 +141,17 @@ msdev env guide dev-122 --write ./host-env-guide.md
|
|
|
109
141
|
```
|
|
110
142
|
|
|
111
143
|
Guides are stored under `~/.config/msdev/guides/nodes/` and
|
|
112
|
-
`~/.config/msdev/guides/environments
|
|
113
|
-
|
|
144
|
+
`~/.config/msdev/guides/environments/`. **Node guides** document how to
|
|
145
|
+
connect; **Env guides** document how to initialize shared context (`setup`).
|
|
146
|
+
|
|
147
|
+
```bash
|
|
148
|
+
msdev env add dev-122-root \
|
|
149
|
+
--node dev-122 \
|
|
150
|
+
--setup-file ./setup-root.sh \
|
|
151
|
+
--wrap sudo --wrap -n --wrap --
|
|
152
|
+
|
|
153
|
+
msdev env open dev-122-root
|
|
154
|
+
```
|
|
114
155
|
|
|
115
156
|
Open a human-operated interactive shell in an Env:
|
|
116
157
|
|
|
@@ -119,21 +160,7 @@ msdev env shell dev-122
|
|
|
119
160
|
msdev env shell dev-122 --cwd /srv/project
|
|
120
161
|
```
|
|
121
162
|
|
|
122
|
-
|
|
123
|
-
conda/venv/uv layers. Exiting returns
|
|
124
|
-
to the local shell. Only the shell session start and final status are visible
|
|
125
|
-
to msdev; commands typed inside it are not individually logged. Agent
|
|
126
|
-
automation should continue using `msdev exec`.
|
|
127
|
-
|
|
128
|
-
Create another Env on the same Node for Docker and Python layers:
|
|
129
|
-
|
|
130
|
-
```bash
|
|
131
|
-
msdev env add dev-122-vllm \
|
|
132
|
-
--node dev-122 \
|
|
133
|
-
--docker-container vllm-ascend \
|
|
134
|
-
--layer conda:base \
|
|
135
|
-
--layer venv:/srv/project/.venv
|
|
136
|
-
```
|
|
163
|
+
Agent automation should use `msdev exec`, not `env shell`.
|
|
137
164
|
|
|
138
165
|
## File put, get, read, and write
|
|
139
166
|
|
|
@@ -162,13 +189,6 @@ msdev env write dev-122 /srv/project/note.md --file /tmp/note.md \
|
|
|
162
189
|
Read before replacing an existing file. `--expected-sha256` is compare-and-swap
|
|
163
190
|
replacement that refuses to overwrite a changed remote file.
|
|
164
191
|
|
|
165
|
-
## NPU inventory
|
|
166
|
-
|
|
167
|
-
```bash
|
|
168
|
-
msdev npu list --node dev-122 --json
|
|
169
|
-
msdev npu list --all --json
|
|
170
|
-
```
|
|
171
|
-
|
|
172
192
|
## Command execution
|
|
173
193
|
|
|
174
194
|
Commands execute synchronously and stream stdout and stderr to the terminal as
|
|
@@ -185,6 +205,13 @@ msdev exec \
|
|
|
185
205
|
-- python3 run.py
|
|
186
206
|
```
|
|
187
207
|
|
|
208
|
+
Quoted pipelines and `|` tokens are executed through a remote POSIX shell
|
|
209
|
+
(`sh -c`), so they run on the Node instead of being treated as a single
|
|
210
|
+
executable name. On a Windows `local` Env they use `cmd.exe /s /c`. Prefer
|
|
211
|
+
`sh -c '…'` for complex scripts. Default streaming writes POSIX newlines as
|
|
212
|
+
CRLF on a Windows console so remote line output does not staircase; piped
|
|
213
|
+
CLI output keeps LF.
|
|
214
|
+
|
|
188
215
|
`--timeout-seconds` defaults to `-1` (no deadline). Any positive finite duration
|
|
189
216
|
is also accepted. A positive timeout kills the complete command
|
|
190
217
|
process group and returns exit code 124. Cancelling the local CLI closes the RPC
|
|
@@ -195,30 +222,13 @@ serialization.
|
|
|
195
222
|
`--result-json` selects captured, non-streaming execution and prints one
|
|
196
223
|
structured JSON result containing stdout and stderr.
|
|
197
224
|
|
|
198
|
-
## Model inventory
|
|
199
|
-
|
|
200
|
-
Examples:
|
|
201
|
-
|
|
202
|
-
```bash
|
|
203
|
-
msdev model discover --node dev-122 --root /data/models
|
|
204
|
-
msdev model list --node dev-122 --json
|
|
205
|
-
msdev model list --all --json
|
|
206
|
-
msdev model inspect model://qwen/Qwen3-32B@main --node dev-122
|
|
207
|
-
msdev model validate model://qwen/Qwen3-32B@main --node dev-122
|
|
208
|
-
msdev model audit --node dev-122
|
|
209
|
-
```
|
|
210
|
-
|
|
211
|
-
Use `msdev model --help` and the individual subcommand help for register,
|
|
212
|
-
update, replicas, refresh, verify, export, import, and rebind.
|
|
213
|
-
|
|
214
225
|
## Architecture
|
|
215
226
|
|
|
216
227
|
```text
|
|
217
228
|
msdev CLI
|
|
218
229
|
-> typed core service
|
|
219
230
|
-> UnixRpcTransport or SshRpcTransport
|
|
220
|
-
-> per-user msdevd
|
|
221
|
-
-> host/container command, env file transfer, NPU, or inventory
|
|
231
|
+
-> per-user msdevd (env session + job runner + files)
|
|
222
232
|
```
|
|
223
233
|
|
|
224
234
|
Remote RPC responses and command output are bounded. Node/Env registries use
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
# msdev
|
|
2
2
|
|
|
3
|
-
`msdev`
|
|
4
|
-
|
|
5
|
-
optional conda/venv/uv layers.
|
|
3
|
+
`msdev` exposes three capabilities: **`node`** (connect + host agent),
|
|
4
|
+
**`env`** (shared execution context, shell, files), and **`exec`** (commands).
|
|
6
5
|
|
|
7
|
-
|
|
6
|
+
A Node owns SSH reachability and `msdevd` deployment. An Env owns the full
|
|
7
|
+
execution context: host or Docker runtime, conda/venv/uv layers, optional
|
|
8
|
+
`setup` script (root switch, proxy, etc.), command `wrap`, and static env vars.
|
|
8
9
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
- no harness conversation binding or implicit current Env exists;
|
|
12
|
-
- MCP is not part of the architecture.
|
|
10
|
+
The CLI is intentionally stateless: execution always names `--env` explicitly.
|
|
11
|
+
MCP is not part of the architecture.
|
|
13
12
|
|
|
14
13
|
## Install
|
|
15
14
|
|
|
@@ -37,6 +36,12 @@ implement ControlMaster multiplexing, so msdev:
|
|
|
37
36
|
`env put`/`get` stay on scp/ssh streams (file bytes do not go through JSON RPC);
|
|
38
37
|
- hides SSH console windows (`CREATE_NO_WINDOW`) and kills process trees with
|
|
39
38
|
`taskkill /T` on timeout or cancel;
|
|
39
|
+
- SSH is non-interactive: `BatchMode` unless a password is supplied, host keys
|
|
40
|
+
use `accept-new`, and there is no password/passphrase/yes-no prompt. When a
|
|
41
|
+
password is known, injects OpenSSH `SSH_ASKPASS` so `node connect` (and later
|
|
42
|
+
ssh/scp) can authenticate without a TTY; the local public key is then
|
|
43
|
+
installed on the Node so later logins are passwordless. The password is
|
|
44
|
+
never written to the node registry;
|
|
40
45
|
- serves a TCP loopback endpoint for local `msdevd` when this Python build has
|
|
41
46
|
no `AF_UNIX` sockets.
|
|
42
47
|
|
|
@@ -60,17 +65,44 @@ msdev node list
|
|
|
60
65
|
msdev node status dev-122
|
|
61
66
|
```
|
|
62
67
|
|
|
63
|
-
Adding a Node atomically creates a same-named host Env.
|
|
64
|
-
the remote
|
|
68
|
+
Adding a Node atomically creates a same-named host Env. Connect deploys and
|
|
69
|
+
starts the remote `msdevd` when needed:
|
|
65
70
|
|
|
66
71
|
```bash
|
|
67
|
-
msdev node
|
|
72
|
+
msdev node connect dev-122
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
Connect uploads a **static Go msdevd** binary matching the node architecture
|
|
76
|
+
(`linux-amd64` / `linux-arm64`) when the agent is missing or stale. No Python
|
|
77
|
+
is required on the node.
|
|
78
|
+
|
|
79
|
+
Build the static daemons before release or local testing:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
bash msdevd/build-static.sh
|
|
83
|
+
bash file-helper/build-static.sh
|
|
68
84
|
```
|
|
69
85
|
|
|
70
|
-
|
|
86
|
+
Packaged artifacts live under `src/msdev/helpers/` (gitignored until built).
|
|
87
|
+
The Go source is in `msdev/`.
|
|
88
|
+
|
|
89
|
+
Persistent OpenSSH masters are optional. All SSH from msdev is
|
|
90
|
+
non-interactive: host keys use `accept-new`, and password/passphrase prompts
|
|
91
|
+
are disabled. Supply a password via environment or file (never a prompt);
|
|
92
|
+
connect then installs the local public key (`~/.ssh/id_ed25519`, generated
|
|
93
|
+
if missing) so later connections are passwordless:
|
|
71
94
|
|
|
72
95
|
```bash
|
|
96
|
+
# Environment (also used by exec / env put after connect if persist is off)
|
|
97
|
+
export MSDEV_SSH_PASSWORD='...'
|
|
98
|
+
export MSDEV_SSH_PASSWORD_DEV_122='...' # per-node override
|
|
99
|
+
|
|
73
100
|
msdev node connect dev-122
|
|
101
|
+
msdev node connect dev-122 --password-file FILE
|
|
102
|
+
msdev node connect dev-122 --password-env VAR
|
|
103
|
+
msdev node connect dev-122 --password PASSWORD # non-interactive; visible in ps
|
|
104
|
+
msdev node connect dev-122 --identity FILE # choose which key to install
|
|
105
|
+
msdev node connect dev-122 --no-install-key # password only, do not copy key
|
|
74
106
|
msdev node disconnect dev-122
|
|
75
107
|
```
|
|
76
108
|
|
|
@@ -84,8 +116,17 @@ msdev env guide dev-122 --write ./host-env-guide.md
|
|
|
84
116
|
```
|
|
85
117
|
|
|
86
118
|
Guides are stored under `~/.config/msdev/guides/nodes/` and
|
|
87
|
-
`~/.config/msdev/guides/environments
|
|
88
|
-
|
|
119
|
+
`~/.config/msdev/guides/environments/`. **Node guides** document how to
|
|
120
|
+
connect; **Env guides** document how to initialize shared context (`setup`).
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
msdev env add dev-122-root \
|
|
124
|
+
--node dev-122 \
|
|
125
|
+
--setup-file ./setup-root.sh \
|
|
126
|
+
--wrap sudo --wrap -n --wrap --
|
|
127
|
+
|
|
128
|
+
msdev env open dev-122-root
|
|
129
|
+
```
|
|
89
130
|
|
|
90
131
|
Open a human-operated interactive shell in an Env:
|
|
91
132
|
|
|
@@ -94,21 +135,7 @@ msdev env shell dev-122
|
|
|
94
135
|
msdev env shell dev-122 --cwd /srv/project
|
|
95
136
|
```
|
|
96
137
|
|
|
97
|
-
|
|
98
|
-
conda/venv/uv layers. Exiting returns
|
|
99
|
-
to the local shell. Only the shell session start and final status are visible
|
|
100
|
-
to msdev; commands typed inside it are not individually logged. Agent
|
|
101
|
-
automation should continue using `msdev exec`.
|
|
102
|
-
|
|
103
|
-
Create another Env on the same Node for Docker and Python layers:
|
|
104
|
-
|
|
105
|
-
```bash
|
|
106
|
-
msdev env add dev-122-vllm \
|
|
107
|
-
--node dev-122 \
|
|
108
|
-
--docker-container vllm-ascend \
|
|
109
|
-
--layer conda:base \
|
|
110
|
-
--layer venv:/srv/project/.venv
|
|
111
|
-
```
|
|
138
|
+
Agent automation should use `msdev exec`, not `env shell`.
|
|
112
139
|
|
|
113
140
|
## File put, get, read, and write
|
|
114
141
|
|
|
@@ -137,13 +164,6 @@ msdev env write dev-122 /srv/project/note.md --file /tmp/note.md \
|
|
|
137
164
|
Read before replacing an existing file. `--expected-sha256` is compare-and-swap
|
|
138
165
|
replacement that refuses to overwrite a changed remote file.
|
|
139
166
|
|
|
140
|
-
## NPU inventory
|
|
141
|
-
|
|
142
|
-
```bash
|
|
143
|
-
msdev npu list --node dev-122 --json
|
|
144
|
-
msdev npu list --all --json
|
|
145
|
-
```
|
|
146
|
-
|
|
147
167
|
## Command execution
|
|
148
168
|
|
|
149
169
|
Commands execute synchronously and stream stdout and stderr to the terminal as
|
|
@@ -160,6 +180,13 @@ msdev exec \
|
|
|
160
180
|
-- python3 run.py
|
|
161
181
|
```
|
|
162
182
|
|
|
183
|
+
Quoted pipelines and `|` tokens are executed through a remote POSIX shell
|
|
184
|
+
(`sh -c`), so they run on the Node instead of being treated as a single
|
|
185
|
+
executable name. On a Windows `local` Env they use `cmd.exe /s /c`. Prefer
|
|
186
|
+
`sh -c '…'` for complex scripts. Default streaming writes POSIX newlines as
|
|
187
|
+
CRLF on a Windows console so remote line output does not staircase; piped
|
|
188
|
+
CLI output keeps LF.
|
|
189
|
+
|
|
163
190
|
`--timeout-seconds` defaults to `-1` (no deadline). Any positive finite duration
|
|
164
191
|
is also accepted. A positive timeout kills the complete command
|
|
165
192
|
process group and returns exit code 124. Cancelling the local CLI closes the RPC
|
|
@@ -170,30 +197,13 @@ serialization.
|
|
|
170
197
|
`--result-json` selects captured, non-streaming execution and prints one
|
|
171
198
|
structured JSON result containing stdout and stderr.
|
|
172
199
|
|
|
173
|
-
## Model inventory
|
|
174
|
-
|
|
175
|
-
Examples:
|
|
176
|
-
|
|
177
|
-
```bash
|
|
178
|
-
msdev model discover --node dev-122 --root /data/models
|
|
179
|
-
msdev model list --node dev-122 --json
|
|
180
|
-
msdev model list --all --json
|
|
181
|
-
msdev model inspect model://qwen/Qwen3-32B@main --node dev-122
|
|
182
|
-
msdev model validate model://qwen/Qwen3-32B@main --node dev-122
|
|
183
|
-
msdev model audit --node dev-122
|
|
184
|
-
```
|
|
185
|
-
|
|
186
|
-
Use `msdev model --help` and the individual subcommand help for register,
|
|
187
|
-
update, replicas, refresh, verify, export, import, and rebind.
|
|
188
|
-
|
|
189
200
|
## Architecture
|
|
190
201
|
|
|
191
202
|
```text
|
|
192
203
|
msdev CLI
|
|
193
204
|
-> typed core service
|
|
194
205
|
-> UnixRpcTransport or SshRpcTransport
|
|
195
|
-
-> per-user msdevd
|
|
196
|
-
-> host/container command, env file transfer, NPU, or inventory
|
|
206
|
+
-> per-user msdevd (env session + job runner + files)
|
|
197
207
|
```
|
|
198
208
|
|
|
199
209
|
Remote RPC responses and command output are bounded. Node/Env registries use
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "msdev"
|
|
7
|
-
version = "0.
|
|
7
|
+
version = "0.12.0"
|
|
8
8
|
description = "Portable nodes and execution environments for msModelSlim development"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
@@ -44,7 +44,7 @@ package-dir = { "" = "src" }
|
|
|
44
44
|
where = ["src"]
|
|
45
45
|
|
|
46
46
|
[tool.setuptools.package-data]
|
|
47
|
-
msdev = ["helpers/msdev-file-helper-*"]
|
|
47
|
+
msdev = ["helpers/msdev-file-helper-*", "helpers/msdevd-linux-*"]
|
|
48
48
|
|
|
49
49
|
[tool.pytest.ini_options]
|
|
50
50
|
testpaths = ["tests"]
|