- Notifications
You must be signed in to change notification settings - Fork928
feat(cli): create workspace using parameters from existing workspace#10604
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Looks good to me! Just an edge case I'd like to see tested, and some potential speed-ups in creation.
template := coderdtest.CreateTemplate(t, client, owner.OrganizationID, version.ID) | ||
// Firstly, create a regular workspace using template with parameters. | ||
inv, root := clitest.New(t, "create", "my-workspace", "--template", template.Name, "-y", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
NB: we now havedbfake.WorkspaceWithAgent if you want to speed things up
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
WorkspaceWithAgent
looks efficient, but I need a workspace with build parameters and a corresponding template with rich parameters. Not sure if the function supports it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
😢 🎺
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
matifali commentedNov 9, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
May be we should call it We can put a disclaimer that it only copies the parameters and not the data stored in persisted resources. |
mtojek commentedNov 9, 2023 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Fixes:#9923
This PR adds support for duplicating workspace using CLI. It is implemented as part of the
coder create
command according to thisdesign (thanks@Parkreiner!).