Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature]: Automatically stop inactive dev environments #2268

Closed
4 of 5 tasks
jvstme opened this issue Feb 5, 2025 · 0 comments
Closed
4 of 5 tasks

[Feature]: Automatically stop inactive dev environments #2268

jvstme opened this issue Feb 5, 2025 · 0 comments
Assignees
Labels

Comments

@jvstme
Copy link
Collaborator

jvstme commented Feb 5, 2025

Problem

Some engineers forget to stop their dev environments, resulting in unnecessary charges.

Solution

Allow to configure the inactivity duration for dev environments.

type: dev-environment
ide: vscode

inactivity_duration: 2h

If a dev environment has been inactive for the configured amount of time, it will be automatically terminated.

Inactivity can be defined as a lack of SSH connections. Internal connections from dstack-server should be ignored and not count as activity. It is also acceptable to ignore short-lived connections lasting only a few seconds.

The default is to disable automatic termination (inactivity_duration: off).

Implementation plan

Workaround

Users could implement this outside of dstack using the API.

max_duration can also work for some use cases.

Would you like to help us implement this feature by sending a PR?

Yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant