Skip to content

Commit a83bdcc

Browse files
Deploying to gh-pages from @ dstackai/dstack@ea851ed 🚀
1 parent 057c7b1 commit a83bdcc

File tree

3 files changed

+81
-36
lines changed

3 files changed

+81
-36
lines changed

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

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ The CLI applies configurations via `dstack apply`, which provisions infrastructu
3838

3939
**Important:** Use `--help` with any CLI command if uncertain about usage or available options.
4040

41+
**Best practices:**
42+
- Prefer giving run configurations a `name` property for easier management and identification
43+
- Prefer modifying configuration files over passing parameters to `dstack apply` (unless it's an exception)
44+
- When user confirms deletion/stop operations, use `-y` flag to skip confirmation prompts
45+
- Many dstack commands require confirmation - pay attention to command output and respond appropriately rather than waiting indefinitely
46+
4147
## Configuration types
4248

4349
`dstack` supports five main configuration types, each with specific use cases. Configuration files can be named `<name>.dstack.yml` or simply `.dstack.yml`.
@@ -241,17 +247,26 @@ volumes:
241247

242248
### Apply Configurations
243249

250+
**Important behavior:**
251+
- `dstack apply` shows a plan with estimated costs and may ask for confirmation (respond with `y` or use `-y` flag to skip)
252+
- Once confirmed, it provisions infrastructure and streams real-time output to the terminal
253+
- In attached mode (default), the terminal blocks and shows output - use timeout or Ctrl+C to interrupt if you need to continue with other commands
254+
- In detached mode (`-d`), runs in background without blocking the terminal
255+
244256
```bash
245257
# Apply and attach (interactive, blocks terminal with port forwarding)
246258
dstack apply -f train.dstack.yml
247259
260+
# Apply with automatic confirmation
261+
dstack apply -f train.dstack.yml -y
262+
248263
# Apply detached (background, no attachment)
249264
dstack apply -f serve.dstack.yml -d
250265
251266
# Force rerun
252267
dstack apply -f finetune.dstack.yml --force
253268
254-
# Override defaults
269+
# Override defaults (prefer modifying config file instead, unless it's an exception)
255270
dstack apply -f .dstack.yml --max-price 2.5
256271
```
257272

@@ -270,11 +285,11 @@ dstack fleet get my-fleet
270285
# Get fleet details as JSON (for troubleshooting)
271286
dstack fleet get my-fleet --json
272287
273-
# Delete entire fleet
274-
dstack fleet delete my-fleet
288+
# Delete entire fleet (use -y when user already confirmed)
289+
dstack fleet delete my-fleet -y
275290
276-
# Delete specific instance from fleet
277-
dstack fleet delete-instance my-fleet <instance-id>
291+
# Delete specific instance from fleet (use -y when user already confirmed)
292+
dstack fleet delete-instance my-fleet <instance-id> -y
278293
```
279294

280295
### Monitor Runs
@@ -303,11 +318,11 @@ dstack run get my-run-name --json
303318
**Note:** `dstack apply` automatically attaches when run completes provisioning. Use `dstack attach` to reconnect after detaching or to access detached runs.
304319

305320
```bash
306-
# Attach to existing run (restores port forwarding + SSH)
307-
dstack attach my-run-name
308-
309-
# Attach and replay logs from start
321+
# Attach and replay logs from start (preferred, unless asked otherwise)
310322
dstack attach my-run-name --logs
323+
324+
# Attach without replaying logs (restores port forwarding + SSH only)
325+
dstack attach my-run-name
311326
```
312327

313328
### View Logs
@@ -332,11 +347,11 @@ dstack logs my-run-name --job 0
332347
# Stop specific run
333348
dstack stop my-run-name
334349
350+
# Stop with confirmation skipped (use when user already confirmed)
351+
dstack stop my-run-name -y
352+
335353
# Abort (force stop)
336354
dstack stop my-run-name --abort
337-
338-
# Stop all runs
339-
dstack stop --all
340355
```
341356

342357
### Check available resources

SKILL.md

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ The CLI applies configurations via `dstack apply`, which provisions infrastructu
3838

3939
**Important:** Use `--help` with any CLI command if uncertain about usage or available options.
4040

41+
**Best practices:**
42+
- Prefer giving run configurations a `name` property for easier management and identification
43+
- Prefer modifying configuration files over passing parameters to `dstack apply` (unless it's an exception)
44+
- When user confirms deletion/stop operations, use `-y` flag to skip confirmation prompts
45+
- Many dstack commands require confirmation - pay attention to command output and respond appropriately rather than waiting indefinitely
46+
4147
## Configuration types
4248

4349
`dstack` supports five main configuration types, each with specific use cases. Configuration files can be named `<name>.dstack.yml` or simply `.dstack.yml`.
@@ -241,17 +247,26 @@ volumes:
241247

242248
### Apply Configurations
243249

250+
**Important behavior:**
251+
- `dstack apply` shows a plan with estimated costs and may ask for confirmation (respond with `y` or use `-y` flag to skip)
252+
- Once confirmed, it provisions infrastructure and streams real-time output to the terminal
253+
- In attached mode (default), the terminal blocks and shows output - use timeout or Ctrl+C to interrupt if you need to continue with other commands
254+
- In detached mode (`-d`), runs in background without blocking the terminal
255+
244256
```bash
245257
# Apply and attach (interactive, blocks terminal with port forwarding)
246258
dstack apply -f train.dstack.yml
247259
260+
# Apply with automatic confirmation
261+
dstack apply -f train.dstack.yml -y
262+
248263
# Apply detached (background, no attachment)
249264
dstack apply -f serve.dstack.yml -d
250265
251266
# Force rerun
252267
dstack apply -f finetune.dstack.yml --force
253268
254-
# Override defaults
269+
# Override defaults (prefer modifying config file instead, unless it's an exception)
255270
dstack apply -f .dstack.yml --max-price 2.5
256271
```
257272

@@ -270,11 +285,11 @@ dstack fleet get my-fleet
270285
# Get fleet details as JSON (for troubleshooting)
271286
dstack fleet get my-fleet --json
272287
273-
# Delete entire fleet
274-
dstack fleet delete my-fleet
288+
# Delete entire fleet (use -y when user already confirmed)
289+
dstack fleet delete my-fleet -y
275290
276-
# Delete specific instance from fleet
277-
dstack fleet delete-instance my-fleet <instance-id>
291+
# Delete specific instance from fleet (use -y when user already confirmed)
292+
dstack fleet delete-instance my-fleet <instance-id> -y
278293
```
279294

280295
### Monitor Runs
@@ -303,11 +318,11 @@ dstack run get my-run-name --json
303318
**Note:** `dstack apply` automatically attaches when run completes provisioning. Use `dstack attach` to reconnect after detaching or to access detached runs.
304319

305320
```bash
306-
# Attach to existing run (restores port forwarding + SSH)
307-
dstack attach my-run-name
308-
309-
# Attach and replay logs from start
321+
# Attach and replay logs from start (preferred, unless asked otherwise)
310322
dstack attach my-run-name --logs
323+
324+
# Attach without replaying logs (restores port forwarding + SSH only)
325+
dstack attach my-run-name
311326
```
312327

313328
### View Logs
@@ -332,11 +347,11 @@ dstack logs my-run-name --job 0
332347
# Stop specific run
333348
dstack stop my-run-name
334349
350+
# Stop with confirmation skipped (use when user already confirmed)
351+
dstack stop my-run-name -y
352+
335353
# Abort (force stop)
336354
dstack stop my-run-name --abort
337-
338-
# Stop all runs
339-
dstack stop --all
340355
```
341356

342357
### Check available resources

skill.md

Lines changed: 27 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,12 @@ The CLI applies configurations via `dstack apply`, which provisions infrastructu
3838

3939
**Important:** Use `--help` with any CLI command if uncertain about usage or available options.
4040

41+
**Best practices:**
42+
- Prefer giving run configurations a `name` property for easier management and identification
43+
- Prefer modifying configuration files over passing parameters to `dstack apply` (unless it's an exception)
44+
- When user confirms deletion/stop operations, use `-y` flag to skip confirmation prompts
45+
- Many dstack commands require confirmation - pay attention to command output and respond appropriately rather than waiting indefinitely
46+
4147
## Configuration types
4248

4349
`dstack` supports five main configuration types, each with specific use cases. Configuration files can be named `<name>.dstack.yml` or simply `.dstack.yml`.
@@ -241,17 +247,26 @@ volumes:
241247

242248
### Apply Configurations
243249

250+
**Important behavior:**
251+
- `dstack apply` shows a plan with estimated costs and may ask for confirmation (respond with `y` or use `-y` flag to skip)
252+
- Once confirmed, it provisions infrastructure and streams real-time output to the terminal
253+
- In attached mode (default), the terminal blocks and shows output - use timeout or Ctrl+C to interrupt if you need to continue with other commands
254+
- In detached mode (`-d`), runs in background without blocking the terminal
255+
244256
```bash
245257
# Apply and attach (interactive, blocks terminal with port forwarding)
246258
dstack apply -f train.dstack.yml
247259
260+
# Apply with automatic confirmation
261+
dstack apply -f train.dstack.yml -y
262+
248263
# Apply detached (background, no attachment)
249264
dstack apply -f serve.dstack.yml -d
250265
251266
# Force rerun
252267
dstack apply -f finetune.dstack.yml --force
253268
254-
# Override defaults
269+
# Override defaults (prefer modifying config file instead, unless it's an exception)
255270
dstack apply -f .dstack.yml --max-price 2.5
256271
```
257272

@@ -270,11 +285,11 @@ dstack fleet get my-fleet
270285
# Get fleet details as JSON (for troubleshooting)
271286
dstack fleet get my-fleet --json
272287
273-
# Delete entire fleet
274-
dstack fleet delete my-fleet
288+
# Delete entire fleet (use -y when user already confirmed)
289+
dstack fleet delete my-fleet -y
275290
276-
# Delete specific instance from fleet
277-
dstack fleet delete-instance my-fleet <instance-id>
291+
# Delete specific instance from fleet (use -y when user already confirmed)
292+
dstack fleet delete-instance my-fleet <instance-id> -y
278293
```
279294

280295
### Monitor Runs
@@ -303,11 +318,11 @@ dstack run get my-run-name --json
303318
**Note:** `dstack apply` automatically attaches when run completes provisioning. Use `dstack attach` to reconnect after detaching or to access detached runs.
304319

305320
```bash
306-
# Attach to existing run (restores port forwarding + SSH)
307-
dstack attach my-run-name
308-
309-
# Attach and replay logs from start
321+
# Attach and replay logs from start (preferred, unless asked otherwise)
310322
dstack attach my-run-name --logs
323+
324+
# Attach without replaying logs (restores port forwarding + SSH only)
325+
dstack attach my-run-name
311326
```
312327

313328
### View Logs
@@ -332,11 +347,11 @@ dstack logs my-run-name --job 0
332347
# Stop specific run
333348
dstack stop my-run-name
334349
350+
# Stop with confirmation skipped (use when user already confirmed)
351+
dstack stop my-run-name -y
352+
335353
# Abort (force stop)
336354
dstack stop my-run-name --abort
337-
338-
# Stop all runs
339-
dstack stop --all
340355
```
341356

342357
### Check available resources

0 commit comments

Comments
 (0)