Conversation
Foundation layer with Template, StorageSpec, Entry structs and all I/O functions: Save, Load, LoadFromPath, Resolve, List, ListAll, Delete, ValidateName, AutoDescription. Includes comprehensive tests. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Register verda template (alias: tmpl) in the Resource Commands group with a list subcommand that reads templates from ~/.verda/templates/ and supports --type filtering and structured output (JSON/YAML). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Add WizardMode type to buildCreateFlow so the same wizard definition can drive both VM deployment (full wizard) and template creation (config steps only, no hostname/description/confirm). Existing WizardModeDeploy path produces identical behavior to before. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Export TemplateResult type and RunTemplateWizard function so the template create command can run the wizard in template mode and get structured results. Also capture human-readable names alongside IDs for SSH keys and startup scripts during wizard selection. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Extract template types/IO into shared internal/verda-cli/template package to break the import cycle between cmd/template and cmd/vm. The cmd/template package re-exports all types and functions via aliases for backward compatibility. Add --from flag to vm create that loads a saved template, applies its values to create options, resolves SSH key and startup script names to IDs via the API, and prints a summary before running the wizard for any remaining fields. When invoked with no flags at all, offers a template picker with "Start from scratch" option. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Add timeout context around SSH key and startup script name resolution to prevent hanging on unresponsive API (per CLAUDE.md convention) - Add comment about single-storage-entry limitation in applyTemplate - Add unit tests for applyTemplate (full, on-demand, partial templates) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Validation errors (spaces, uppercase, duplicates) now display inline and let the user try again instead of failing the command. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
"My Quick Test" → "my-quick-test", "GPU_Training" → "gpu-training". Lowercases, replaces spaces/underscores with hyphens, strips invalid chars. Shows the reformatted name before proceeding. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Uses Cobra's NoOptDefVal so --from alone triggers the picker, while --from=gpu-training loads a specific template. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
verda vm create (no flags) now goes straight to the wizard. Template picker only appears with --from or --from=name. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
--from gpu-training (space-separated) now works like all other flags. Removed NoOptDefVal picker behavior for consistency. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
--from alone shows a template picker, --from gpu-training loads the template directly. Both space-separated and = syntax work. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
billing_type=on-demand and location=FIN-01 from templates were not recognized as "set" by the wizard, causing re-prompts. Added billingTypeSet and locationSet flags to distinguish template values from defaults. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When creating a template, "None (skip)" for storage and startup script is now saved as storage_skip/startup_script_skip in the YAML. Using --from with such a template correctly skips those wizard steps. Also fixed startup script name capture: "None (skip)" label was incorrectly stored as the script name. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When --from pre-fills all config steps, the confirm step now fetches instance type and volume type pricing from the API so the deployment summary shows accurate costs instead of $0. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Templates can now include hostname_pattern (e.g. "gpu-{random}-{location}")
which auto-expands when using --from, skipping the hostname prompt.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- 14 new tests covering skip flags, hostname pattern, edge cases - README.md with full usage guide, YAML format, and examples - CLAUDE.md with AI context, gotchas, and relationships Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
template create: explain YAML format, auto-reformat, hostname_pattern. vm create: show --from examples (name, file, picker) prominently. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Tests for NVMe and HDD storage from templates, verifying StorageSize, StorageType, and storageSkip flag behavior. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Type of Change
Checklist
make test)make pre-commit)Related Issues
Additional Context