-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Description
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
When a template has Require workspaces automatically update when started enabled (require_active_version = true), running coder start from the CLI (or via the VS Code extension, which calls coder start under the hood) starts the workspace with the old template version instead of updating to the active template version.
The web UI and server-side autostart correctly enforce the update, but the CLI does not.
Impact:
This also affects the VS Code Coder extension (tested with v1.12.2), which calls coder start --yes to start workspaces. Organizations relying on require_active_version to enforce template updates on start will find that the policy is not enforced when workspaces are started via the CLI or VS Code extension.
Relevant Log Output
N/AExpected Behavior
coder start should update the workspace to the active template version before starting, matching the behavior of the web UI and server-side autostart.
Steps to Reproduce
- Create a template with
Require workspaces automatically update when started enabled - Create a workspace from the template
- Push a new version to the template
- Stop the workspace
- Run
coder start <owner>/<workspace>from the CLI - Observe that the workspace starts with the old template version
Environment
- Host OS:
- Coder version: 2.25.6, 2.26.6, 2.28.6, and 2.29.6 - Tests were performed on these versions but this issue predates these versions.
Additional Context
No response