Skip to content

Commit 74ae68c

Browse files
Deploying to gh-pages from @ dstackai/dstack@b166b9e 🚀
1 parent 326cef9 commit 74ae68c

File tree

34 files changed

+1602
-1533
lines changed

34 files changed

+1602
-1533
lines changed

.well-known/skills/dstack/SKILL.md

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -101,27 +101,29 @@ If you need to prompt for next actions, be explicit about the dstack step and co
101101

102102
`dstack attach` runs until interrupted and blocks the terminal. **Agents must avoid indefinite blocking.** If a brief attach is needed, use a timeout to capture initial output (IDE link, SSH alias) and then detach.
103103

104-
Note: `dstack attach` writes SSH alias info under `~/.dstack/ssh/config` (and may update `~/.ssh/config`) to enable `ssh <run-name>`, IDE connections, port forwarding, and real-time logs (`dstack attach --logs`). If the sandbox cannot write there, the alias will not be created.
104+
Note: `dstack attach` writes SSH alias info under `~/.dstack/ssh/config` (and may update `~/.ssh/config`) to enable `ssh <run name>`, IDE connections, port forwarding, and real-time logs (`dstack attach --logs`). If the sandbox cannot write there, the alias will not be created.
105+
106+
**Permissions guardrail:** If `dstack attach` fails due to sandbox permissions, request permission escalation to run it outside the sandbox. If escalation isn’t approved or attach still fails, ask the user to run `dstack attach` locally and share the IDE link/SSH alias output.
105107

106108
**Background attach (non-blocking default for agents):**
107109
```bash
108-
nohup dstack attach <run-name> --logs > /tmp/<run-name>.attach.log 2>&1 & echo $! > /tmp/<run-name>.attach.pid
110+
nohup dstack attach <run name> --logs > /tmp/<run name>.attach.log 2>&1 & echo $! > /tmp/<run name>.attach.pid
109111
```
110112
Then read the output:
111113
```bash
112-
tail -n 50 /tmp/<run-name>.attach.log
114+
tail -n 50 /tmp/<run name>.attach.log
113115
```
114116
Offer live follow only if asked:
115117
```bash
116-
tail -f /tmp/<run-name>.attach.log
118+
tail -f /tmp/<run name>.attach.log
117119
```
118120
Stop the background attach (preferred):
119121
```bash
120-
kill "$(cat /tmp/<run-name>.attach.pid)"
122+
kill "$(cat /tmp/<run name>.attach.pid)"
121123
```
122124
If the PID file is missing, fall back to a specific match (avoid killing all attaches):
123125
```bash
124-
pkill -f "dstack attach <run-name>"
126+
pkill -f "dstack attach <run name>"
125127
```
126128
**Why this helps:** it keeps the attach session alive (including port forwarding) while the agent remains usable. IDE links and SSH instructions appear in the log file -- surface them and ask whether to open the link (`open "<link>"` on macOS, `xdg-open "<link>"` on Linux) only after explicit approval.
127129

@@ -131,7 +133,7 @@ If background attach fails in the sandbox (permissions writing `~/.dstack` or `~
131133

132134
**"Run something":** When the user asks to run a workload (dev environment, task, service), use `dstack apply` with the appropriate configuration. Note: `dstack run` only supports `dstack run get --json` for retrieving run details -- it cannot start workloads.
133135

134-
**"Connect to" or "open" a dev environment:** If a dev environment is already running, use `dstack attach <run-name> --logs` (agent runs it in the background by default) to surface the IDE URL (`cursor://`, `vscode://`, etc.) and SSH alias. If sandboxed attach fails, request escalation or ask the user to run attach locally and share the link.
136+
**"Connect to" or "open" a dev environment:** If a dev environment is already running, use `dstack attach <run name> --logs` (agent runs it in the background by default) to surface the IDE URL (`cursor://`, `vscode://`, etc.) and SSH alias. If sandboxed attach fails, request escalation or ask the user to run attach locally and share the link.
135137

136138
## Configuration types
137139

@@ -187,7 +189,7 @@ resources:
187189
gpu: A100:40GB:2
188190
```
189191
190-
**Port forwarding:** When you specify `ports`, `dstack apply` forwards them to `localhost` while attached. Use `dstack attach <run-name>` to reconnect and restore port forwarding. The run name becomes an SSH alias (e.g., `ssh <run-name>`) for direct access.
192+
**Port forwarding:** When you specify `ports`, `dstack apply` forwards them to `localhost` while attached. Use `dstack attach <run name>` to reconnect and restore port forwarding. The run name becomes an SSH alias (e.g., `ssh <run name>`) for direct access.
191193

192194
**Distributed training:** Multi-node tasks are supported (e.g., via `nodes`) and require fleets that support inter-node communication (see `placement: cluster` in fleets).
193195

@@ -217,9 +219,16 @@ resources:
217219
```
218220

219221
**Service endpoints:**
220-
- Without gateway: `<dstack server URL>/proxy/services/<project name>/<run name>/`
222+
- Without gateway: `<dstack server URL>/proxy/services/f/<run name>/`
221223
- With gateway: `https://<run name>.<gateway domain>/`
222-
- For OpenAI-compatible models, use the `/v1/...` paths under the service URL and pass the dstack token in the `Authorization` header.
224+
- Authentication: Unless `auth` is `false`, include `Authorization: Bearer <DSTACK_TOKEN>` on all service requests.
225+
- OpenAI-compatible models: Use `service.url` from `dstack run get <run name> --json` and append `/v1` as the base URL; do **not** use deprecated `service.model.base_url` for requests.
226+
- Example (with gateway):
227+
```bash
228+
curl -sS -X POST "https://<run name>.<gateway domain>/v1/chat/completions" \
229+
-H "Authorization: Bearer <dstack token>" \
230+
-H "Content-Type: application/json" \
231+
-d '{"model":"<model name>","messages":[{"role":"user","content":"Hello"}],"max_tokens":64}'
223232
224233
[Concept documentation](https://dstack.ai/docs/concepts/services.md) | [Configuration reference](https://dstack.ai/docs/reference/dstack.yml/service.md)
225234
@@ -235,7 +244,7 @@ resources:
235244
gpu: 24GB..
236245
disk: 200GB
237246

238-
spot_policy: auto
247+
spot_policy: auto # other values: spot, on-demand
239248
idle_duration: 5m
240249
```
241250

SKILL.md

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -101,27 +101,29 @@ If you need to prompt for next actions, be explicit about the dstack step and co
101101

102102
`dstack attach` runs until interrupted and blocks the terminal. **Agents must avoid indefinite blocking.** If a brief attach is needed, use a timeout to capture initial output (IDE link, SSH alias) and then detach.
103103

104-
Note: `dstack attach` writes SSH alias info under `~/.dstack/ssh/config` (and may update `~/.ssh/config`) to enable `ssh <run-name>`, IDE connections, port forwarding, and real-time logs (`dstack attach --logs`). If the sandbox cannot write there, the alias will not be created.
104+
Note: `dstack attach` writes SSH alias info under `~/.dstack/ssh/config` (and may update `~/.ssh/config`) to enable `ssh <run name>`, IDE connections, port forwarding, and real-time logs (`dstack attach --logs`). If the sandbox cannot write there, the alias will not be created.
105+
106+
**Permissions guardrail:** If `dstack attach` fails due to sandbox permissions, request permission escalation to run it outside the sandbox. If escalation isn’t approved or attach still fails, ask the user to run `dstack attach` locally and share the IDE link/SSH alias output.
105107

106108
**Background attach (non-blocking default for agents):**
107109
```bash
108-
nohup dstack attach <run-name> --logs > /tmp/<run-name>.attach.log 2>&1 & echo $! > /tmp/<run-name>.attach.pid
110+
nohup dstack attach <run name> --logs > /tmp/<run name>.attach.log 2>&1 & echo $! > /tmp/<run name>.attach.pid
109111
```
110112
Then read the output:
111113
```bash
112-
tail -n 50 /tmp/<run-name>.attach.log
114+
tail -n 50 /tmp/<run name>.attach.log
113115
```
114116
Offer live follow only if asked:
115117
```bash
116-
tail -f /tmp/<run-name>.attach.log
118+
tail -f /tmp/<run name>.attach.log
117119
```
118120
Stop the background attach (preferred):
119121
```bash
120-
kill "$(cat /tmp/<run-name>.attach.pid)"
122+
kill "$(cat /tmp/<run name>.attach.pid)"
121123
```
122124
If the PID file is missing, fall back to a specific match (avoid killing all attaches):
123125
```bash
124-
pkill -f "dstack attach <run-name>"
126+
pkill -f "dstack attach <run name>"
125127
```
126128
**Why this helps:** it keeps the attach session alive (including port forwarding) while the agent remains usable. IDE links and SSH instructions appear in the log file -- surface them and ask whether to open the link (`open "<link>"` on macOS, `xdg-open "<link>"` on Linux) only after explicit approval.
127129

@@ -131,7 +133,7 @@ If background attach fails in the sandbox (permissions writing `~/.dstack` or `~
131133

132134
**"Run something":** When the user asks to run a workload (dev environment, task, service), use `dstack apply` with the appropriate configuration. Note: `dstack run` only supports `dstack run get --json` for retrieving run details -- it cannot start workloads.
133135

134-
**"Connect to" or "open" a dev environment:** If a dev environment is already running, use `dstack attach <run-name> --logs` (agent runs it in the background by default) to surface the IDE URL (`cursor://`, `vscode://`, etc.) and SSH alias. If sandboxed attach fails, request escalation or ask the user to run attach locally and share the link.
136+
**"Connect to" or "open" a dev environment:** If a dev environment is already running, use `dstack attach <run name> --logs` (agent runs it in the background by default) to surface the IDE URL (`cursor://`, `vscode://`, etc.) and SSH alias. If sandboxed attach fails, request escalation or ask the user to run attach locally and share the link.
135137

136138
## Configuration types
137139

@@ -187,7 +189,7 @@ resources:
187189
gpu: A100:40GB:2
188190
```
189191
190-
**Port forwarding:** When you specify `ports`, `dstack apply` forwards them to `localhost` while attached. Use `dstack attach <run-name>` to reconnect and restore port forwarding. The run name becomes an SSH alias (e.g., `ssh <run-name>`) for direct access.
192+
**Port forwarding:** When you specify `ports`, `dstack apply` forwards them to `localhost` while attached. Use `dstack attach <run name>` to reconnect and restore port forwarding. The run name becomes an SSH alias (e.g., `ssh <run name>`) for direct access.
191193

192194
**Distributed training:** Multi-node tasks are supported (e.g., via `nodes`) and require fleets that support inter-node communication (see `placement: cluster` in fleets).
193195

@@ -217,9 +219,16 @@ resources:
217219
```
218220

219221
**Service endpoints:**
220-
- Without gateway: `<dstack server URL>/proxy/services/<project name>/<run name>/`
222+
- Without gateway: `<dstack server URL>/proxy/services/f/<run name>/`
221223
- With gateway: `https://<run name>.<gateway domain>/`
222-
- For OpenAI-compatible models, use the `/v1/...` paths under the service URL and pass the dstack token in the `Authorization` header.
224+
- Authentication: Unless `auth` is `false`, include `Authorization: Bearer <DSTACK_TOKEN>` on all service requests.
225+
- OpenAI-compatible models: Use `service.url` from `dstack run get <run name> --json` and append `/v1` as the base URL; do **not** use deprecated `service.model.base_url` for requests.
226+
- Example (with gateway):
227+
```bash
228+
curl -sS -X POST "https://<run name>.<gateway domain>/v1/chat/completions" \
229+
-H "Authorization: Bearer <dstack token>" \
230+
-H "Content-Type: application/json" \
231+
-d '{"model":"<model name>","messages":[{"role":"user","content":"Hello"}],"max_tokens":64}'
223232
224233
[Concept documentation](https://dstack.ai/docs/concepts/services.md) | [Configuration reference](https://dstack.ai/docs/reference/dstack.yml/service.md)
225234
@@ -235,7 +244,7 @@ resources:
235244
gpu: 24GB..
236245
disk: 200GB
237246

238-
spot_policy: auto
247+
spot_policy: auto # other values: spot, on-demand
239248
idle_duration: 5m
240249
```
241250

docs/concepts/backends.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -853,7 +853,7 @@ Then, go ahead and configure the backend:
853853
projects:
854854
- name: main
855855
backends:
856-
- type: datacrunch
856+
- type: verda
857857
creds:
858858
type: api_key
859859
client_id: xfaHBqYEsArqhKWX-e52x3HH7w8T

docs/concepts/backends/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5241,7 +5241,7 @@ <h3 id="verda">Verda (formerly DataCrunch)<a class="headerlink" href="#verda" ti
52415241
<div class="highlight"><pre><span></span><code><span class="nt">projects</span><span class="p">:</span>
52425242
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">name</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">main</span>
52435243
<span class="w"> </span><span class="nt">backends</span><span class="p">:</span>
5244-
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">datacrunch</span>
5244+
<span class="w"> </span><span class="p p-Indicator">-</span><span class="w"> </span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">verda</span>
52455245
<span class="w"> </span><span class="nt">creds</span><span class="p">:</span>
52465246
<span class="w"> </span><span class="nt">type</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">api_key</span>
52475247
<span class="w"> </span><span class="nt">client_id</span><span class="p">:</span><span class="w"> </span><span class="l l-Scalar l-Scalar-Plain">xfaHBqYEsArqhKWX-e52x3HH7w8T</span>

docs/guides/protips.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -439,10 +439,10 @@ Getting offers...
439439
---> 100%
440440
441441
# BACKEND REGION INSTANCE TYPE RESOURCES SPOT PRICE
442-
1 datacrunch FIN-01 1H100.80S.30V 30xCPU, 120GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
443-
2 datacrunch FIN-02 1H100.80S.30V 30xCPU, 120GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
444-
3 datacrunch FIN-02 1H100.80S.32V 32xCPU, 185GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
445-
4 datacrunch ICE-01 1H100.80S.32V 32xCPU, 185GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
442+
1 verda FIN-01 1H100.80S.30V 30xCPU, 120GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
443+
2 verda FIN-02 1H100.80S.30V 30xCPU, 120GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
444+
3 verda FIN-02 1H100.80S.32V 32xCPU, 185GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
445+
4 verda ICE-01 1H100.80S.32V 32xCPU, 185GB, 1xH100 (80GB), 100.0GB (disk) no $2.19
446446
5 runpod US-KS-2 NVIDIA H100 PCIe 16xCPU, 251GB, 1xH100 (80GB), 100.0GB (disk) no $2.39
447447
6 runpod CA NVIDIA H100 80GB HBM3 24xCPU, 251GB, 1xH100 (80GB), 100.0GB (disk) no $2.69
448448
7 nebius eu-north1 gpu-h100-sxm 16xCPU, 200GB, 1xH100 (80GB), 100.0GB (disk) no $2.95

0 commit comments

Comments
 (0)