Skip to content

feat: label the bucket kind Object Storage, and follow the menu's order - #164

Open
Fermionic-Lyu wants to merge 1 commit into
mainfrom
feat/object-storage-label
Open

feat: label the bucket kind Object Storage, and follow the menu's order#164
Fermionic-Lyu wants to merge 1 commit into
mainfrom
feat/object-storage-label

Conversation

@Fermionic-Lyu

@Fermionic-Lyu Fermionic-Lyu commented Aug 31, 2026

Copy link
Copy Markdown
Member

Companion to InsForge/insta-frontend#343, which regroups the console's Add Service menu and relabels the bucket source.

SERVICE_KINDS carries a comment declaring "Same order, labels and default names as the dashboard's Add Service menu", and before #343 its list matched item for item. Two changes keep that true:

  • StorageObject Storage. The console's src/lib/api/usage.ts already used that word for this billing dimension, with the reason recorded there: it must not read as disk (volume keeps the industry word). The Usage tab and invoice rows have said "Object Storage" all along; the pickers said "Storage".
  • Empty Service moves from last to directly after Docker Image, matching the menu's new order.

Display-only. Every lookup is by key, never position: resolve-service.ts finds by k.type === type && !k.needsImage (exactly one non-image kind per type, so first-match is unambiguous) and the picker resolves by k.id. The non-interactive path returns before SERVICE_KINDS is read at all. test/resolve-service.test.ts pins the full label list and goes red on either drift — verified by mutating both back.

Also fixed in the comment this PR exists to keep true:

  • It enumerated one omission (Github Repo) and there are two — Template was never in this list either.
  • Its reason for dropping Github Repo — "the platform has no repo path yet" — is contradicted in this repo: src/commands/deploy.ts:37-39 describes the GitHub-connected nixpacks lane as real and server-side, and :53 tells users to use it. The omission is still right; the reason was not. Neither Github Repo nor Template is a type-and-name create, which is why insta services add has no shape for them.

npm run typecheck && npm test pass (47 files, 672 tests). The agent-facing mirror required by AGENTS.md #4 is InsForge/insta-skills#68 — that row also still said "four kinds", stale since redis/mysql/mongodb landed.


Summary by cubic

Aligns the CLI's service kind list with the dashboard's Add Service menu: the bucket kind is now labeled Object Storage instead of Storage, and Empty Service moves up to sit beside Docker Image. This is display-only; lookups are by key, so no behavior changes. The parity comment now names both omitted kinds (Github Repo and View Templates) and the real reason they're omitted: neither is a type-and-name create, so insta services add has no shape for them.

Written for commit 16f06ad. Summary will update on new commits.

Review in cubic

@agent-zhang-beihai agent-zhang-beihai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed by Wang Miao

This renames the storage kind's picker label to Object Storage and moves Empty Service up beside Docker Image in SERVICE_KINDS, with the parity test updated to the new sequence. I checked the claim against the dashboard: insta-frontend PR 343 (feat: group the add-service sources by what they get you, still open) is exactly what this mirrors — it relabels storage to Object Storage, recategorises compute into the code group beside Docker Image, and pushes Template into its own section, so the new CLI order and the new "Github Repo and Template are left out" comment both hold once that lands. No findings; approving.

Nothing else in the repo keys off these labels or their order — serviceKindLines() only pads them for display (Object Storage is exactly the 14-char pad width, so the column stays aligned), and the picker resolves on id, not label.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 2 files

You’re at about 94% of the monthly reviewed-line limit. You may want to disable incremental reviews to conserve quota. Reviews will continue until that limit is exceeded. If you need help avoiding interruptions, please contact contact@cubic.dev.

Re-trigger cubic

@agent-zhang-beihai agent-zhang-beihai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed by Yang Dong

This aligns the service picker’s label and ordering with the dashboard while preserving stable service IDs and provisioning behavior. The updated test pins the intended presentation. APPROVE — no findings.

The console's Add Service menu is this list's declared source of truth for order,
labels and default names. It now labels the bucket source Object Storage -- the
word the Usage tab already used, so it cannot read as disk -- and lists Empty
Service beside Docker Image rather than last.

The parity comment claimed one omission and had two; Template was never in this
list either. Its stated reason for dropping Github Repo was also false: that lane
is real (nixpacks server-side, see deploy.ts). Neither entry is a type-and-name
create, which is the actual reason `insta services add` has no shape for them.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@Fermionic-Lyu
Fermionic-Lyu force-pushed the feat/object-storage-label branch from 1bec801 to 16f06ad Compare August 31, 2026 20:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant