You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`timeout` is a hard execution deadline by default. If you add `reset on output`, it becomes an inactivity timeout instead: every new stdout or stderr chunk from the running command resets the timer.
224
225
@@ -231,6 +232,18 @@ Example:
231
232
232
233
This step can run longer than 30 seconds overall as long as it keeps producing CLI output at least once every 30 seconds. If output stops for 30 seconds, the step times out.
233
234
235
+
### The `interactive` keyword — terminal-interactive steps
236
+
237
+
The engine automatically detects steps that read from the terminal (`read`, `/dev/tty`, `ssh-copy-id`) and suspends live-progress rendering while they own the terminal. For commands the heuristic cannot detect, add the `interactive` keyword to the step body:
238
+
239
+
```cgr
240
+
[set password]:
241
+
run $ passwd deploy_user
242
+
interactive
243
+
```
244
+
245
+
This forces PTY allocation and stdin forwarding regardless of the command name. Use it for tools like `passwd`, `kinit`, `gpg --gen-key`, or any other utility that opens the terminal directly.
246
+
234
247
### The `first` keyword — why not `after`?
235
248
236
249
When reading `[install nginx]`, the dependency keyword should answer "what does this step need?" from the perspective of the step you're currently reading.
@@ -1129,6 +1142,7 @@ resource install_nginx {
1129
1142
|`on_fail`| No |`stop`| What to do on failure: `stop` (abort the graph), `warn` (continue, mark as warned), `ignore` (treat as success). |
1130
1143
|`when`| No |`null`| Quoted boolean expression. If false, the resource is skipped. Supports `==` and `!=`. |
1131
1144
|`env`| No |`{}`| Set environment variables. Syntax: `env KEY = "value"`. Repeatable. |
1145
+
|`interactive`| No |`false`| Force terminal-interactive mode (PTY + stdin forwarding). Use for commands like `passwd`, `kinit`, or any tool that reads directly from the terminal. The engine auto-detects common patterns (`read`, `/dev/tty`, `ssh-copy-id`); use this keyword for others. |
0 commit comments